3 ms·
There's a ton of great responses in this thread. Allow me to go a bit meta: this is a big topic, and as you enter it, you'll eventually find out which parts of
by hyperpape 8y ago
There's a ton of great responses in this thread. Allow me to go a bit meta: this is a big topic, and as you enter it, you'll eventually find out which parts of it appeal to you. Do you care about parsers? Type theory? Garbage collection? Code generation/optimization? Notation as a tool for thought?
Ever since I started programming, the idea of writing my own language was a sort of "white whale". I have one idea for a language that I think could be usable in a very particular domain. For that, I wrote a very primitive tree-walking interpreter (terrible performance, very technically uninteresting). The idea for the language was what I wanted to explore. I recently started writing a regex->jvm bytecode compiler. That's much lower level, and if I stick with it, performance will be what I optimize for. In neither case did I do anything interesting with parsers, though I used to love learning about new parsing techniques.
In that vein, see dfox's suggestion to "just use hand built recursive descent parser and some set of ad-hoc lexical analysis subroutines". That's the fastest way to get started, whether or not it'll be the best in the long term.
So, my advice is to explore and figure out which things you're interested in, and what you want to accomplish. That will tell you where you want to invest your time.