News for hackers. Stuff that matters.
Re:Roy — small functional language that compiles to JavaScript by archivator on Friday November 25, 2011 @10:46AM (#3277312)
Currying is a nice-to-have but definitely not a requirement for a usable functional language. It might be possible to add it to Roy by abusing JavaScript dictionaries and identifying functions that are partially applied but I'm not convinced it's worth the effort.
Re:Roy — small functional language that compiles to JavaScript by amalcon on Friday November 25, 2011 @11:12AM (#3277386)
Currying is very easy to implement in terms of lexical closures.
Re:Roy — small functional language that compiles to JavaScript by masklinn on Saturday November 26, 2011 @10:53AM (#3279977)
Sure, but that can get costly fast (at runtime) when the language implementations are not highly optimized for funcalling and recursion (javascript VMs tends not to be), so ideally you'd only use partial application in the underlying (compiler result) code when that's needed rather than have all functions be curried.