Re: [frogs] Adding docstring support to def-grace-function |
[ Thread Index |
Date Index
| More lilynet.net/frogs Archives
]
- To: frogs@xxxxxxxxxxx
- Subject: Re: [frogs] Adding docstring support to def-grace-function
- From: "Patrick McCarty" <pnorcks@xxxxxxxxx>
- Date: Wed, 7 Jan 2009 11:03:04 -0800
- Cc: lily-devel <lilypond-devel@xxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=ZvOoUdPT9rBCzLkyrp4vNx8ZIAF5vflIqxEs8JMjxVc=; b=FwBiutgWUxgeyVL0krogWPRQ1eHB9Yyx8I3YZyc+ByXfCG9NgihglAUpQl4olVMVQj VBHsKWIMxH4jZ149Hzz7BSZ7y2Dn4TcI6rBE5tUQQAYiqHX+7JaSfEfBu8rDPkZikhvY oXK0TiSLXdEv6sjoy/EpUKQmmOgN7xGb3n49c=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=oIznJq7ynYT7/WKw79Cx2TPAU3qQ0JwZppjbqCmkmLjKhjEvcyTD7bIJ8Jm7Ovsu8w IZH+F5PX/2Za7gVthotV8bJgvTjRIgjEyvwFQ3z7wKeSX3Frh6Z9z5gTLKe8t/uVp88n 4w9nzILGgDcv9LuMyI7Zdsan5lKHCQmeZHbyE=
On Wed, Jan 7, 2009 at 7:40 AM, Carl D. Sorensen <c_sorensen@xxxxxxx> wrote:
>
> On 1/7/09 12:51 AM, "Patrick McCarty" <pnorcks@xxxxxxxxx> wrote:
>>
>> For A., using acciaccatura as an example, I propose the following syntax:
>>
>> acciaccatura =
>> #(def-grace-function (_i "add docstring") startAcciaccaturaMusic
>> stopAcciaccaturaMusic)
>
> There are two reasons I'd like to try something different than this syntax.
>
> First, docstrings always come after the arguments to the function.
Ah, yes. I did not think this through carefully enough.
> Second this syntax would require a convert-ly rule, and so would need to
> wait until work begins on 2.13.
Okay, I understand this now.
> A syntax that would not require a convert-ly rule would be
>
> acciaccatura =
> #(def-grace-function startAcciaccaturaMusic stopAcciaccaturaMusic
> (_i "Here is the docstring."))
>
> because the docstring argument can be written as an optional argument
> in the macro definition for def-grace-function. So adding a docstring
> is a syntax addition, not a change, and no convert-ly rule is needed.
I see a few Scheme procedures that use the #:optional keyword. This
is what you are referring to, right?
Thanks,
Patrick
---
----
Join the Frogs!