source file of the GNU LilyPond music typesetter
- (c) 1997--1998 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+ (c) 1997--1999 Han-Wen Nienhuys <hanwen@cs.uu.nl>
*/
#include <strstream.h>
#include "notename-table.hh"
#include "interval.hh"
#include "identifier.hh"
-#include "assoc-iter.hh"
#include "parser.hh"
#include "keyword.hh"
-#include "assoc.hh"
#include "my-lily-lexer.hh"
#include "debug.hh"
#include "source-file.hh"
#include "scope.hh"
static Keyword_ent the_key_tab[]={
- {"absdynamic", ABSDYNAMIC},
+ {"spanrequest", SPANREQUEST},
{"accepts", ACCEPTS},
{"alternative", ALTERNATIVE},
{"bar", BAR},
{"clef", CLEF},
{"cm", CM_T},
{"consists", CONSISTS},
+ {"consistsend", CONSISTSEND},
+ {"context", CONTEXT},
{"duration", DURATION},
{"font", FONT},
{"grouping", GROUPING},
{"script", SCRIPT},
{"shape", SHAPE},
{"skip", SKIP},
- {"table", TABLE},
- {"spandynamic", SPANDYNAMIC},
- {"symboltables", SYMBOLTABLES},
+ {"textscript", TEXTSCRIPT},
{"tempo", TEMPO},
{"translator", TRANSLATOR},
- {"type", TYPE},
{"transpose", TRANSPOSE},
+ {"type", TYPE},
{"version", VERSION},
{0,0}
};
Identifier*
My_lily_lexer::lookup_identifier (String s)
{
+ SCM sym = ly_symbol (s.ch_C());
+
for (int i = scope_l_arr_.size (); i--; )
- if (scope_l_arr_[i]->elem_b (s))
- return (*scope_l_arr_[i])[s];
+ if (scope_l_arr_[i]->elem_b (sym))
+ return scope_l_arr_[i]->elem(sym);
return 0;
}
warning ( _f ("Identifier name is a keyword (`%s')", name_str));
}
- (*scope_l_arr_.top ())[name_str] = i;
+ scope_l_arr_.top ()->elem (name_str) = i;
}
My_lily_lexer::~My_lily_lexer()