3 ms·
I'd go even further. Minimize the exposure time to parsers. We started my undergrad compilers class with several weeks on parsing. I think it's by far the ha
by ken 7y ago
I'd go even further. Minimize the exposure time to parsers.
We started my undergrad compilers class with several weeks on parsing. I think it's by far the hardest aspect in all of compilerdom -- and as a Lisp programmer, I didn't understand the need to be tortured that way.
I do understand on a theory level why parsers would get put first in a compiler class, but they're a tremendous barrier to entry and just make the whole subject seem inaccessible. There's lots of other ways I can think of which would make it easier for newcomers to get some traction on the subject of compilers.
- kd0amg 7y agoLet's go another step. Move parsing into a mandatory class on automata theory, where you can properly dig into the machine models underlying different parsing algorithms.
- UncleOxidant 7y agoI don't agree that parsing is the hardest aspect in all of compilerdom. More like parsing is the least interesting part of what makes a compiler. Perhaps as you allude to, use Lisp or S-expressions as the frontend language and then build the compiler as you don't need much of a parser. Then you can get straight to the more interesting bits.