4 ms·
Scheme in Ruby.
- wrs 16y agoWow, that seems...backwards.
- wrs 16y agoThat was funny, the comment got upvoted and then downvoted. So perhaps I'm not the only one who would be interested to hear examples of situations in which one would want a Scheme interpreter implemented in Ruby. There isn't much of a rationale in the README. On the other hand, a Ruby interpreter implemented in Scheme would be interesting as an attempt to nail down the ever-elusive semantics of Ruby, if nothing else. If, as another commenter mentioned, there are "Ruby shops" where one would have to sneak Scheme in through this mechanism, then I guess Ruby has truly reached the mainstream.
- jcoglan 16y agoThe rationale is that I wanted to learn how to write an interpreter, particularly some of the more challenging parts like tail recursion, macros, continuations and laziness. It's in Ruby because that's what I know best; it's not intended for production use as a replacement for Ruby, though I have used it myself to do a little code transformation and testing in Ruby apps. So basically it's a toy, but one that I hope others can learn something from.
- mmaunder 16y ago( ( ( ( (cool) ) ) ) )
- hakl 16y agoYour parentheses look lonely :(.
- judofyr 16y agoHeist is definitely one of the better-designed interpreter I've seen. I've been a James Coglan-fan ever since I stumbled upon it! He also has an excellent video where he creates a Scheme interpreter in 15 minutes (no sound unfortunately): http://vimeo.com/4339116 http://vimeo.com/4339116
- mahmud 16y agoI wrote a lengthy post about this earlier but it seems like i have closed the browser before posting :-/ Long story short, this one is exceptionally well done and the author seems like an actual Schemer, which is a major plus. The interpreter doesn't have a prompt, so it looks stuck ;-) I would use it if I was stuck in a Ruby shop; this is industrial strength stuff.