TyOverby / ares

A Lisp made for easy integration with Rust.
9 stars 1 forks source link

rest args #37

Open bwo opened 9 years ago

bwo commented 9 years ago

like (lambda (one two . rest) ...) or (lambda (one two #rest rest) or whatever the syntax should be.

TyOverby commented 9 years ago

I'm a fan of the dot syntax.

Maybe . should be a reserved character to make method syntax easier; I don't know how to build it into the Ast though...

bwo commented 9 years ago

. can just be a regular symbol that the lambda form recognizes. For that matter it can be a regular symbol (mapped to a macro-like function) for the purposes of #38 if we adopt something like Clojure's syntax, (. player move x y).