lilypond-auto
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Lilypond-auto] Issue 3139 in lilypond: Replace abuse of Moment type for


From: lilypond
Subject: [Lilypond-auto] Issue 3139 in lilypond: Replace abuse of Moment type for everything rational
Date: Fri, 25 Jan 2013 12:32:16 +0000

Status: Accepted
Owner: ----

New issue 3139 by address@hidden: Replace abuse of Moment type for everything rational
http://code.google.com/p/lilypond/issues/detail?id=3139

For historical as well as irrational (why not create a Scheme type corresponding to C++ Rational?) reasons, LilyPond has used the Moment type as a Scheme level substitute for rational arithmetic, dating back to a time when GUILE did not support rational arithmetic.

Associated peculiarities includes operators like ly:moment-add, ly:moment-sub, ly:moment-mul and similar usage ranging from the strange to the absurd. The use of moments should be replaced with Scheme rationals whenever there is no chance that the grace part of the moment can't possibly be non-zero.

In addition, it might well make sense to not use it for any kind of length, either, since moment arithmetic including grace length is inconsistent anyway, and reduce its use to indicating only absolute time positions.

Doing this thoroughly will significantly reduce the battleground for issues like issue 3085 and issue 34.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]