Cormorant
Cormorant copied to clipboard
Add support for #() macro
Add support for the inline function reader macro (e.g. #(doSomething %0 %1)
). Expanding this macro is relatively straightforward, with the caveat that the expander needs to know know many %n
tokens there are (or if only %
is used).
A good resource is: http://stackoverflow.com/questions/13204993/anonymous-function-shorthand
Actually... %n
tokens are 1-indexed, %
is always %1
, and however many tokens there are is determined by the highest n
value. Finally, #()
can't be nested.