Skip to content

Argument Enhancements (Defaults and Splats) #16

@jashkenas

Description

@jashkenas

Think about adding argument defaults to CoffeeScript function definitions. Something along the lines of:

start_reading: book, page: 1 => ...

Ideally, the arguments with default values could occur anywhere in the list.

Also, splats to siphon up the rest of the arguments:

demolition: *condominiums => wreck(condo) for condo in condominiums..

Neither of these should be too hard to implement -- both can be accomplished by inserting an expression that does the work at the top of the Code body.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions