Hacker News new | ask | show | jobs
by mayoms 3343 days ago
I think that you should be a bit more transparent about how much of Thorston's ideas and code you are using in this project. You should probably give him some attribution.

I also read that book, and have a toy language I've been building, basically extending his ideas. I've looked through your code and much of is it nearly verbatim from the book (including code in your 'vm', or the monkey 'eval' package - it's not just the lexer/parser), though you (as I have), chose different names, or organized things differently, and added new features.

Yes, you've extended his ideas much farther, but the core of 'rooby' is pretty much the same as Thorston's language, 'monkey'.

Monkey is available with the MIT license, so it's fine what you've done. But, having been through the book and pretty familiar with the Monkey code (available for download here: https://interpreterbook.com/waiig_code_1.3.zip), I think it's disingenuous to say 'I read that book before this project..', which seems to imply that it was inspiration, rather than original source material.

On a positive note, it's a pretty cool version of Monkey.

2 comments

The 'code' you read is similar, but the way they work are totally different.

Monkey is fundamentally a functional language, but rooby is totally an object oriented language. And the compiler, vm's internal implementation and bytecode spec, which are the 'core' of rooby, is not like monkey at all.

I would say I extended monkey's lexer and parser as rooby's. I feel sorry if I didn't give enough credit to Thorston, I would add reference to his book in readme. But the core is more a Ruby than monkey, so I don't think it's just an "extension" of monkey.

Please read the commits and you'll know how much work I did to make rooby, it's far more complicated than just "extend" monkey.

BTW here's the monkey source code I wrote when I practiced with the book https://github.com/st0012/monkey