Le 30 août 09 à 03:20, Carl Sorensen a écrit :




On 8/29/09 7:01 PM, "Reinhold Kainhofer" <reinh...@kainhofer.com> wrote:



You mean something like this patch:
  http://codereview.appspot.com/112044

LGTM.

Just a question. In your regression test, you first define (add-one- score
#f), then you set! it to a lambda function.

Is that solely so that you can have pitch defined in the lexical scope but outside of add-one-score? Or is there more going on that I haven't figured
out?

Yes, that's to build a closure.
Now, as there is only one function using pitch, it can be simplied to
(define add-one-score
   (let ((pitch 0))
     (lambda (parser) ...)))



_______________________________________________
lilypond-devel mailing list
lilypond-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-devel

Reply via email to