You might not be excited about “implementing a slow version of Java in Java”, but that doesn’t make it a bad approach. (Also, second part is about implementing same interpreter in C)
Re:Contents • Build Your Own Lisp
by grumpyprole on Saturday April 29, 2023 @11:36AM
(#35753927)
Well implementing all the OOP semantics and such could complicate and dilute the essentials. A simpler language would also make it easier to cover more ground, such as type checking.
So I don't think it sounds ideal from a pedagogical perspective either, but again, I haven't read the book.
Java in Java isn't slow, it is a matter of how it is done.
JikesRVM, MaximeVM and now GraalVM.
Re:Contents • Build Your Own Lisp
by grumpyprole on Sunday April 30, 2023 @03:42PM
(#35765939)
I agree but the context was interpreters. GraalVM is a compiler, it JIT compiles bytecode into machine code.
If one wants to learn specifically how Java works, then maybe a book on compilers would be better?