2 scope.cc -- implement Scope
4 source file of the GNU LilyPond music typesetter
6 (c) 1998--2000 Han-Wen Nienhuys <hanwen@cs.uu.nl>
12 #include "scm-hash.hh"
14 Scope::Scope (Scheme_hash_table
* st
)
21 Scope::elem_b (String s
) const
23 return id_dict_
->elem_b (ly_symbol2scm (s
.ch_C()));
27 Scope::elem_b (SCM s
) const
29 return id_dict_
->elem_b (s
);
34 Scope::scm_elem (SCM s
)const
36 return id_dict_
->get (s
);
40 Scope::scm_elem (String s
) const
42 return scm_elem (ly_symbol2scm (s
.ch_C()));
47 Scope::set (String s
, SCM id
)
49 return id_dict_
->set (ly_symbol2scm (s
.ch_C()), id
);
53 Scope::to_alist () const
55 return id_dict_
->to_alist ();
59 Scope::try_retrieve (SCM k
, SCM
*v
)const
61 return id_dict_
->try_retrieve (k
, v
);