top | item 42006186

(no title)

dismister | 1 year ago

I'm sure there will be lots of people recommending great books, so i want to give you some general advice:

sadly, a lot of language related libraries are in C/C++, so if using those sounds a pain to you, just ignore them for now.

get somthing simple working soon, such as an interpreter for Forth [0] written in any language you already know.

do the parsing later, there is so much more to learn about compilers and language runtimes!

when it's finally time for parsing, i recommend parser combinators [1]. they are pretty easy to implement yourself, once you have understood the concept and are very flexible.

do not forget about proper error messages with line/col information.

any kind of performance optimisation is strictly forbidden until you know what you are doing.

[0] https://en.m.wikipedia.org/wiki/Forth_(programming_language)

[1] https://www.theorangeduck.com/page/you-could-have-invented-p...

discuss

order

No comments yet.