[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Help with debugging apparent error in parser

From: Neil Puttock
Subject: Re: Help with debugging apparent error in parser
Date: Sat, 9 Aug 2008 00:57:02 +0100

2008/8/8 Carl D. Sorensen <address@hidden>:

> This experience causes me to believe that there is a bug in the parser
> related to chordmode.

I presume you've had a look at lexer.ll?

It seems a bit dodgy to me that Lily_lexer::scan_bare_word () checks
for a match in the chord modifier hash table if YYSTATE == notes *or*
chords; once chordmode is entered, the hash table is initialized, and
will remain live, which produces a false match in notemode for 'm'.

Changing line 827 from

else if ((handle = scm_hashq_get_handle (chordmodifier_tab_, sym)) !=


else if ((YYSTATE == chords)
                      && (handle = scm_hashq_get_handle (chordmodifier_tab_,
sym)) != SCM_BOOL_F)

prevents it from returning an erroneous match in notemode so it can
return a string instead.

Whether this is a proper fix, I'm unsure, but it certainly allows your
snippet to compile OK.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]