lilypond-devel
[Top][All Lists]
Advanced

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

Re: How to procede with \override/\revert business


From: David Kastrup
Subject: Re: How to procede with \override/\revert business
Date: Wed, 31 Oct 2012 12:01:51 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2.50 (gnu/linux)

Janek Warchoł <address@hidden> writes:

> Hmm, if i'm reading git log correctly, i'm too late to give my LGTM to
> pushing these changes... ;)
> Anyway, i'm very happy to see this change!
>
> On Wed, Oct 31, 2012 at 10:07 AM, David Kastrup <address@hidden> wrote:
>> Keith OHara <address@hidden> writes:
>>> In this case since both searches fail I suppose the parser should warn
>>> "cannot recognize the name of any Grob or context-property" but
>>> generate a propertySet on the chance that later input defines a
>>> "Lyric" context and a Scheme engraver that reads a property
>>> "fontsize".
>>
>> I don't think that we should plan for interfaces where you can
>> tentatively use properties before defining them.  There is just too much
>> that can go wrong with that.
>
> I'm not sure if i understand you correctly.
>
> Currently (checked with 2.17.3) i can write this in LilyPond code
> (verbatim):

It likely does not pass 2.17.6.

> {
>   \override Stem #'my-funky-property = #5
> }
> LilyPond will complain about an unknown property name, but the
> property will be set anyway, and i'll be able to access it later.

Unless it makes LilyPond crash.

> I like this possibility.  Is this what you call "using properties
> before defining them"?

That's not even "before defining them" but rather "without defining
them".  Properties are typechecked, and they are maintained in a stack
starting from the Global context.  We have far enough possibilities to
let LilyPond crash with segmentation faults from bad code, and I am not
interested in creating more of them.  In general, if LilyPond has no
idea how to do something reasonably, it is much better if it does
nothing at all rather than letting its internals be poked with a stick
on the assumption that somebody must know what he is doing.

-- 
David Kastrup



reply via email to

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