3 ms·
My favorite language implementation tutorial is "An Incremental Approach to Compiler Construction" by Abdulaziz Ghuloum: http://scheme2006.cs.uchicago.edu/11-gh
by mepian 4y ago
My favorite language implementation tutorial is "An Incremental Approach to Compiler Construction" by Abdulaziz Ghuloum: http://scheme2006.cs.uchicago.edu/11-ghuloum.pdf http://scheme2006.cs.uchicago.edu/11-ghuloum.pdf
What makes it stand out is that it shows you how to build a compiler rather than an interpreter, and shows that it's really not that much more difficult.
There is a book-length "sequel" to this paper that goes into more detail: https://github.com/IUCompilerCourse/Essentials-of-Compilation https://github.com/IUCompilerCourse/Essentials-of-Compilatio...
- jeffrallen 4y agoI did this one too get back into programming after a career change and it worked for me.
- pjmlp 4y agoOne tip I got back in the day (mid-90's), regarding compilers vs interpreters. Make the compiler output some kind of bytecode in a format, which can be easily interpreted, or with the help of a Macro Assembler, very quickly transformed into machine code. It won't win performance prices, however it is quite easy to get going. Naturally fitting these ideas into Lisp like languages is quite straightforward. Thanks for the book tip.