Hello,
as Harm has pointed out, the following example gives unexpected (i.e.
different) output:
\version "2.19"
repeat-note =
#(define-music-function (parser location music)(ly:music?)
(make-sequential-music (list music (ly:music-deep-copy music))))
\absolute { c'1 \repeat-note c'' }
\relative c' { c \repeat-note c'1 }
There are several possible ways of handling this:
– Document it as a feature of ly:music-deep-copy in its search string.
Users would have to circumvent it then.
– Modify ly:music-deep-copy to output both copies in the same octave.
This would be most intuitive for what I think, since one would expect
copies to be identical.
– Provide an optional (?) second argument to ly:music-deep-copy to
choose between the two behaviours: abs-copy to use \relative only for
determining the start of the first copy and start the second copy from
the same absolute pitch; rel-copy to apply \relative also on the first
note of the second copy (as in current behaviour).
– Use two dedicated functions for these two ways of handling it. What
would they be named? I’d suggest ly:music-deep-copy-relative (current
behaviour) and ly:music-deep-copy (new behaviour).
The third option would be easiest in terms of backward compatibility,
the fourth is actually a variant of the second, with an additional
possibility for convert-ly updating.
Yours, Simon
_______________________________________________
bug-lilypond mailing list
bug-lilypond@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-lilypond