4 ms·
> I'm glad I didn't listen to the naysayers, the Debbie Downers, and of course that nameless C guru from long ago, whom I owe thanks to. That's great to hear t
by mattfenwick 13y ago
> I'm glad I didn't listen to the naysayers, the Debbie Downers, and of course that nameless C guru from long ago, whom I owe thanks to.
That's great to hear that you didn't let the negativity stop you.
I was recently told "If you're going to get bogged down trying to get the lexer/parser to work, you're not ready to work on a full blown language/compiler." Hopefully my story will go the same way as yours.
- eru 13y agoAnd that's probably good advice. Take it as: toy around with lexers and parsers a bit before moving on to more complicated subjects. (Or cheat, and stick with a Lisp like syntax.)
- WalterBright 13y agoI'd also recommend that one master algebra before attempting calculus. I don't think that's negativity, it's just recommending an order in which to do things. Negativity would be "you're not smart enough to handle calculus." Not that anyone has ever followed my advice, anyway :-)
- Ygg2 13y agoWell, having a working lexer/parser is needed to make a compiler, but I see very little reason to write your own parser. Lexer yeah, but from what I've heard parsers are tedious and better optimized by programs. Anyway, thing that helps me do stuff - focus on getting a piece of program right. Then move onto another part. Another good saying, all good software starts simple and evolves into a complex solution. So maybe start with Lisp syntax and evolve it into something more complex, when you're ready.
- pmr_ 13y agoInterestingly there is another article by Walter Bright on writing your own compiler on DrDobbs [1] in which he explicitly recommends to write the parser yourself and I have received similar advice by others that know how to implement compilers. My personal experience in implementing a subset of C turned out similar. [1]: http://www.drdobbs.com/architecture-and-design/so-you-want-to-write-your-own-language/240165488 http://www.drdobbs.com/architecture-and-design/so-you-want-t...