Mike Solomon <[email protected]> writes:

> hmm…for a slightly less minimal example, I'm trying to do:
>
> bc = |
>
> foo = { \bc \bar "|" }
>
> {
>  a a a a a \foo
> }
>
> Any ideas on how to accomplish that?

Simple.  First fix
<URL:http://code.google.com/p/lilypond/issues/detail?id=2392>

then revert

commit c83a3afbc51c62769cbb8963371d37b312bbcd42
Author: David Kastrup <[email protected]>
Date:   Wed Feb 27 01:26:14 2013 +0100

    Issue 3205: opening bar check causes crash if \score contains the \midi 
block
    
    This derives Bar_check_iterator from Music_iterator rather than from
    Simple_music_iterator.
    
    In
    \score {
      { | d }
      \midi { }
    }
    
    the bar check iterator is being called while only the \Global context
    exists.  That causes Score_performer::one_time_step to be called
    without getting Score_performer::prepare to be called previously,
    probably because the Score context is created at the wrong time.  The
    Score_performer is not prepared for this situation.
    
    I have no idea how to fix Simple_music_iterator, why it exists in the
    first place and is written like it is, and why this appears to work.


Note the last paragraph of the commit message/review description
pointing out rather explicitly that this was just a stab in the dark.
It would appear that whatever Simple_music_iterator _does_ different
from Music_iterator matters here.

If you can figure out what the difference is, go ahead and document that
as well so that people have a way to figure out in future when
Simple_music_iterator might be called for.

Issue 2392 has some discussion at the end about what might work for
fixing the Midi crash.

-- 
David Kastrup

_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to