2009/1/7 Carl D. Sorensen <[email protected]>: > You can also paste the following in at the guile> prompt, which is obtained > by typing > > guile > > in a terminal window: > > (define (test-opt-args arg1 arg2 . t-opt-args arg1 arg2 . rest) > (display "arg1 ")(display arg1)(newline) > (display "arg2 ")(display arg2)(newline) > (display "rest ")(display rest)(newline)) > (test-opt-args 1 2 3 4 5 6 7 8 9) > > > This will define and execute a procedure named test-opt-args that has two > fixed arguments and the remainder are optional.
As Carl has shown here, the optional arguments are often named `rest'; you'll find a few interesting examples in lilypond by grepping for `. rest'. Regards, Neil _______________________________________________ lilypond-devel mailing list [email protected] http://lists.gnu.org/mailman/listinfo/lilypond-devel
