6 ms·
Let’s Build a Simple Interpreter, Part 2
- stcredzero 11y agoFrom the post: As Ralph Waldo Emerson said: “If you learn only methods, you’ll be tied to your methods. But if you learn principles, you can devise your own methods.” This was one of the main points of "The Trial of the Gang of Four" at OOPSLA '99. Everyone was so busy talking about the patterns that they spent little time thinking about the principles that the patterns were supposed to be talking about. Programming Patterns were also meant as a literature for programmers, not as cookbooks. Maybe this is a bit misguided. Cooks start out following recipes, then learn to apply principles. Recipes can't keep cooks from making bad food, but they can often help cooks make acceptable or even good food.
- dang 11y agoOff topic, but the attribution of that quote to Emerson is probably bogus. https://www.google.com/search?tbo=p&tbm=bks&q=principles+methods+inauthor:%22Ralph+Waldo+Emerson%22&num=10 https://www.google.com/search?tbo=p&tbm=bks&q=principles+met...
- stcredzero 11y agoGood to know!
- xigency 11y agoThose are some pretty heavy reading recommendations for a fairly simple exercise in Python. I wouldn't generally go from making a calculator to working on a compiler. If one were to read a book on compiler theory and design with the intention of writing a compiler, I would recommend the book Engineering a Compiler, however. The book is based on a course taught at Rice University that is fairly comprehensive.
- swah 11y agoProtip: always start a Part N post w/ a paragraph saying "If you haven't read Part N-1, here it is blablabla". (Wow, I feel like patio11 now)
- cardiffspaceman 11y agoThe link is fairly close to the beginning but not right at the top. It consists of the words, "Part 1" with a dotted underline so it would be easy to miss.
- swah 11y agoOh, I found it now!