bug-lilypond
[Top][All Lists]
Advanced

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

Re: Issue 2072 in lilypond: Add proper complex variables to Lilypond


From: David Kastrup
Subject: Re: Issue 2072 in lilypond: Add proper complex variables to Lilypond
Date: Sat, 10 Dec 2011 13:28:18 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.92 (gnu/linux)

Ian Hulin <address@hidden> writes:

> Hi David,
> On 09/12/11 12:55, address@hidden wrote:
>> 
>> Comment #2 on issue 2072 by address@hidden: Add proper complex
>> variables to Lilypond 
>> http://code.google.com/p/lilypond/issues/detail?id=2072
>> 
>> After thinking about it, assignments are possible only in contexts
>> where strings can't occur by themselves. So it should actually be
>> possible to use the syntax violin1 = { ... } or less covert
>> variants of specifying 1.
>> 
>> Of course, only after having declared violin as an array.
> Two questions:
> Which problem are we solving here, numbers as valid characters in Lily
> identifiers,

More the problem of users asking for them.  They just don't know what
they really want(TM) or would not dare asking for.

> or providing some sort of arrays/vectors/subscripted variables
> facility in Lily?  If it's the latter, how would we "declare violin as
> an array"?

> Maybe \array violin 2 and access it as violin[1] = {...}
> violin[2] = {...}

Huh?  I already described the access syntax.  The definition would be
something like

violin = \vector 2

violin1 = {...}

violin2 = {...}

with you being free to write

violin #(+ 3 2) = {...}

or similar instead for the definition and

\violin #(+ 1 2)

for use.

Or
sonata = \vector 2
sonata1 = \struct #'(expo modulation reprise)
sonata1 #'expo = { ... }
sonata1 #'modulation = { ... }
sonata1 #'reprise = { ... }

Something like that.

-- 
David Kastrup




reply via email to

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