Before generating the IR code, it’s good to know the main elements of the IR language. In Chapter 2, The…

Having created a decorated abstract syntax tree (AST) for your programming language, the next task is to generate the LLVM…

These rules are embedded into the semantic analyzer while creating the AST nodes for an expression. Likewise, the type and…

This must be done reliably because we do not want to add names to the wrong scope in case of…

Naturally, the AST nodes are a part of a class hierarchy. A declaration always has a name. Other attributes depend…

Manually constructing a parser and a lexer can be a tedious task, especially if you try to invent a new…