/* Flex >= 2.5.29 fix; FlexLexer.h's multiple include bracing breaks
when building the actual lexer. */
+
#define LEXER_CC
#include <iostream>
+
using namespace std;
+
#include "music-function.hh"
#include "source-file.hh"
#include "parse-scm.hh"
}
}
-<INITIAL,notes>\\encoding{WHITE}* {
+<INITIAL,lyrics,figures,notes>\\encoding{WHITE}* {
yy_push_state (encoding);
}
<INITIAL,chords,lyrics,notes,figures>\\version{WHITE}* {
return INVALID;
}
<renameinput>\"[^"]*\" {
- String s (YYText ()+1);
+ String s (YYText () + 1);
s = s.left_string (s.index_last ('\"'));
yy_pop_state();
this->here_input().source_file_->name_ = s;
- progress_indication ("\n");
- progress_indication (_f ("input renamed to: `%s'", s.to_str0 ()));
+ progress_indication (_f ("Renaming input to: `%s'", s.to_str0 ()));
progress_indication ("\n");
scm_module_define (scm_car (scopes_),
ly_symbol2scm ("input-file-name"),
- scm_makfrom0str (s.to_str0()));
+ scm_makfrom0str (s.to_str0 ()));
}
<encoding>. {
<INITIAL,chords,lyrics,figures,notes>\\include {
yy_push_state (incl);
}
-<incl>\"[^"]*\";? { /* got the include file name */
-/* FIXME: semicolon? */
+<incl>\"[^"]*\" { /* got the include file name */
String s (YYText ()+1);
s = s.left_string (s.index_last ('"'));
new_input (s, sources_);
yy_pop_state ();
}
-<incl>\\{BLACK}*;?{WHITE} { /* got the include identifier */
-/* FIXME: semicolon? */
+<incl>\\{BLACK}*{WHITE} { /* got the include identifier */
String s = YYText () + 1;
strip_trailing_white (s);
if (s.length () && (s[s.length () - 1] == ';'))
yylval.i = String_convert::dec2int (String (YYText () +1));
return E_UNSIGNED;
}
-
\" {
start_quote ();
}
String str (YYText () + 1);
SCM s = lookup_markup_command (str);
- if (ly_c_pair_p (s) && scm_is_symbol (scm_cdr (s)) ) {
+ if (scm_is_pair (s) && scm_is_symbol (scm_cdr (s)) ) {
yylval.scm = scm_car(s);
SCM tag = scm_cdr(s);
if (tag == ly_symbol2scm("markup0"))
SCM sym = ly_symbol2scm (str.to_str0 ());
if ((YYSTATE == notes) || (YYSTATE == chords)) {
SCM handle = SCM_BOOL_F;
- if (ly_c_pair_p (pitchname_tab_stack_))
+ if (scm_is_pair (pitchname_tab_stack_))
handle = scm_hashq_get_handle (scm_car (pitchname_tab_stack_), sym);
- if (ly_c_pair_p (handle)) {
+ if (scm_is_pair (handle)) {
yylval.scm = scm_cdr (handle);
if (unsmob_pitch (yylval.scm))
return (YYSTATE == notes) ? NOTENAME_PITCH : TONICNAME_PITCH;
/* 2.1.2x something -> \property -> \set. */
-Lilypond_version oldest_version ("2.2.0");
+Lilypond_version oldest_version ("2.3.22");
bool
{
return MUSIC_FUNCTION_SCM_SCM_MUSIC;
}
+ else if (type == ly_symbol2scm ("markup"))
+ {
+ return MUSIC_FUNCTION_MARKUP;
+ }
+ else if (type == ly_symbol2scm ("markup-music"))
+ {
+ return MUSIC_FUNCTION_MARKUP_MUSIC;
+ }
+ else if (type == ly_symbol2scm ("markup-markup"))
+ {
+ return MUSIC_FUNCTION_MARKUP_MARKUP;
+ }
+ else if (type == ly_symbol2scm ("markup-music-music"))
+ {
+ return MUSIC_FUNCTION_MARKUP_MUSIC_MUSIC;
+ }
+ else if (type == ly_symbol2scm ("markup-markup-music"))
+ {
+ return MUSIC_FUNCTION_MARKUP_MARKUP_MUSIC;
+ }
else if (type == ly_symbol2scm ("noarg"))
{
return MUSIC_FUNCTION;