Hacker News new | past | comments | ask | show | jobs | submit login

I don't think a direct translation of Ruby -> Javascript would have made much sense, though. It makes much more sense to custom mould a new language to the needs of Javascript, than to try and fit Ruby into a whole new context.

I started looking into making a parser that took CoffeeScript and parsed it into PHP, and the farther I got spec'ing things out, the less the CoffeeScript syntax made sense for the context of PHP. So it would make more sense to start new, and create a new syntax that fits better. I'm assuming the same process may have occurred for CoffeeScript.

Anyways, as someone who greatly prefers Python over Ruby, I love using whitespace for blocks.




Ruby has a 6000 LOC yacc parser for the grammar. I would bet that Coffee's grammar is smaller, tighter, and less full of perlisms.





Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact

Search: