Re:Roy — small functional language that compiles to JavaScript
by Miky on Friday November 25, 2011 @08:33PM
(#3278802)
Monadic sugar is probably not the way to go for implementing an automatic continuation-passing transform. Why not just do macros?
[ Parent
| on HN ]
Re:Roy — small functional language that compiles to JavaScript
by pufuwozu on Friday November 25, 2011 @10:02PM
(#3278941)
Monads suit the problem nicely and it's been done in quite a few languages already:
http://lambda-the-ultimate.org/node/4117
http://ocaml.janestreet.com/?q=node/100
http://en.wikibooks.org/wiki/F_Sharp_Programming/Async_Workf...
This is something that JavaScript desperately needs.
Macros aren't so nice for this stuff in non-homoiconic languages.
Re:Roy — small functional language that compiles to JavaScript
by Miky on Saturday November 26, 2011 @02:11PM
(#3280442)
I previously had a someone antagonistic comment, but I decided to remove it.
I think that finding ways to notate asynchronous code cleanly is a pretty awesome goal, and I hope you find success in your project.