[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Macro pre-processing?
From: |
Nicolas Sceaux |
Subject: |
Re: Macro pre-processing? |
Date: |
Mon, 01 May 2006 22:37:44 +0200 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (darwin) |
"Geoff Horton" <address@hidden> writes:
> Mats Bengtsson <address@hidden> writes:
>> As far as I understand, it should be trivial to make a
>> version of define-music-function where the user doesn't have to add
>> these arguments manually, so the syntax is
>>
>> #(new-define-music-function (arg1 arg2 ... ) (typecheck1 typecheck2 ... )
>> #{ ordinary LilyPond code using $arg1 $arg2 ... #}
>> }
This is manageable indeed :-)
> I think that would satisfy most of my needs.
???
#(new-define-music-function (arg1 arg2 ... )
(typecheck1 typecheck2 ... )
#{ ordinary LilyPond code using $arg1 $arg2 ... #})
satisfies your needs but:
#(define-music-function (parser location arg1 arg2 ... )
(typecheck1 typecheck2 ... )
#{ ordinary LilyPond code using $arg1 $arg2 ... #})
does not?
Ok so the real problem is the two extra parameters...
#(defmacro-public def-mus-fn ;; short name for short version :)
(args typechecks . body)
(let ((parser (gensym))
(location (gensym)))
`(define-music-function (,parser ,location ,@args) ,typechecks
,@body)))
- Re: Macro pre-processing?, Erik Sandberg, 2006/05/01
- Re: Macro pre-processing?, Nicolas Sceaux, 2006/05/01
- Re: Macro pre-processing?, Mats Bengtsson, 2006/05/01
- Re: Macro pre-processing?, Geoff Horton, 2006/05/01
- Re: Macro pre-processing?,
Nicolas Sceaux <=
- Re: Macro pre-processing?, Graham Percival, 2006/05/02
- Re: Macro pre-processing?, Han-Wen Nienhuys, 2006/05/02
- Re: Macro pre-processing?, Mats Bengtsson, 2006/05/02
- Re: Macro pre-processing?, Mats Bengtsson, 2006/05/02
- Re: Macro pre-processing?, Aaron VonderHaar, 2006/05/03
- Re: Macro pre-processing?, Graham Percival, 2006/05/03
- Re: Macro pre-processing?, Rick Hansen (aka RickH), 2006/05/02
- Re: Macro pre-processing?, Erik Sandberg, 2006/05/02
- Re: Macro pre-processing?, Rick Hansen (aka RickH), 2006/05/02
- Re: Macro pre-processing?, David Feuer, 2006/05/02