Experimental compiler based on the .NET Roslyn compiler architecture.
Built for fun and learning!
The purpose is to build a modern compiler that provides an API for manipulating syntax is an efficient immutable fashion. This could be referred to as a "Compiler-as-a-Service".
It is a merger of the projects in the compiler-projects repo.
Look at unit tests.
The Parser and the AST is not yet in sync.
Syntax to be decided. Should it be a C-style language, or something else?
Expression parser logic can be taken from ExpressionEvaluator. This is a Operator-precedence parser, originally based on the IronPython source code (in C#),
The Abstract Syntax Tree (AST) is immutable. And "changing" a syntax node should result in a copy of the tree.
We need to handle syntax trivia - whitespaces, comments, and other things with no meaning.
Re-usable part. Kept when modifying the tree.
Nodes that know their children. But not their parent.