lambda*

[macro] lambda* extended-formals body

SRFI-89: Adds optional positional arguments and named arguments support.

    <extended formals> --> <variable> | ( <extended def formals> )

    <extended def formals> --> <positional section> <named section>? <rest section>
                            |  <named section>? <positional section> <rest section>

    <positional section> --> <required positional>* <optional positional>*

    <required positional> --> <variable>

    <optional positional> --> ( <variable> <expression> )

    <named section> --> <named>+

    <named> --> <required named>
             |  <optional named>

    <required named> --> ( <keyword> <variable> )

    <optional named> --> ( <keyword> <variable> <expression> )

    <rest section> --> . <variable>
                    |  <empty>

See also define*.

Guile: Also supports extended lambda list by lambda*, but separates optional arguments, keyword arguments and rest arguments by #:optional, #:key, and #:rest, a la Common Lisp.

See Concept:ExtendedLambdaList for more discussion.