Graham Percival <gra...@percival-music.ca> writes: > On Wed, Oct 12, 2011 at 05:42:47PM +0200, David Kastrup wrote: >> >> I am currently trying to make music functions more powerful, in >> particular their argument predicates. Also I am trying to relieve the >> parser from responsibilities. > > Looks basically good to me. GLISS was never planned to tackle > scheme stuff, and waiting for GLISS 2 would take 2 years or more > at our current rate of progress. I see no reason to postpone this > change for that long. > >> Now I have a possibly slightly contentious change... I want to let { } >> mimic the new functionality of #{ #} instead of creating sequential >> music unconditionally. That means the following: >> >> previously equivalent to now equivalent to >> { \with ... } syntax error context-modification >> { c4 } \sequential { c4 } simple-music > > What happens if somebody writes > { \with foo c4 \with bar d4 } > ?
Good catch. I don't think we want anything but a syntax error here. One approach would be not to ignore Scheme expressions in a sequence unless they evaluate to "unspecified" or at least a limited set of "ignorable" values. More compatible would be the approach that you can omit braces only when a certain construct is syntactically expected somewhere: if it is to be produced "foreignly", use # or { ... }. Then { { \with foo } c4 { \with bar } d4 } would be a music sequence with two Scheme expressions inside getting ignored, and { \with foo c4 \with bar d4 } would be a syntax error. -- David Kastrup _______________________________________________ lilypond-devel mailing list lilypond-devel@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-devel