On May 18, 2023, at 08:47, Valentin Petzel <valen...@petzel.at> wrote:
> 
> Essentially it checks: Do we start at the begin of a measure, and if so, does 
> or repeated music take exactly one or two measures?

I've dropped the user list from this thread.

I suggest looking at Percent_repeat_iterator::create_contexts().  There is code 
that reads context properties.

Next, read the comment on Music_iterator::create_contexts().  This is the 
salient point:

    // Think twice before reading context properties here.  Other iterators'
    // process () methods may run after this call and before this iterator's
    // process () method runs (and may change the context properties).

Therefore, try deferring the Percent_repeat_iterator's initialization that 
depends on context properties until the first call to process().

You are right that quoting on the whole does not smell sweet, and I don't have 
time now to list the remaining problems I see, but taking the above action 
might mitigate the problem at hand.
— 
Dan

P.S. Include a regression test in your merge request. :)


Reply via email to