[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Error in latest lilypond git HEAD with complex score
From: |
H. S. Teoh |
Subject: |
Re: Error in latest lilypond git HEAD with complex score |
Date: |
Tue, 31 Dec 2024 11:11:52 -0800 |
On Tue, Dec 31, 2024 at 01:55:28PM -0500, Saul Tobin wrote:
> Did you run convert-ly from HEAD?
I just tried it, the only difference in the output is the \version
number.
> On Tue, Dec 31, 2024, 1:53 PM H. S. Teoh via LilyPond user discussion
> <[1]lilypond-user@gnu.org> wrote:
[...]
> > The last good version AFAIK is commit f1ad21caa. The following
> > commit, 6c1081a82, appears to be the change that broke this,
> > though I've no idea why it should, and what my score has to do
> > with it (nowhere in my score do I reference ly:duration-length
> > directly).
Actually, I take that back. I'm using a helper Scheme function I got
from somewhere, that does reference ly:duration-length:
#(define (add-durations dur1 dur2)
(let* ((len1 (ly:duration-length dur1))
(len2 (ly:duration-length dur2))
(mult (ly:moment-div (ly:moment-add len1 len2) len1)))
(ly:make-duration (ly:duration-log dur1)
(ly:duration-dot-count dur1)
(* (ly:duration-scale dur1) (ly:moment-main
mult)))))
How do I update this function to work with the new version of lilypond?
I tried to change duration-length to duration->number but it still gave
me this error:
Parsing...ice-9/eval.scm:159:9: Throw to key `numerical-overflow' with
args `("divide" "Numerical overflow" #f #f)'.
--T