joichiro/xi — pull request #2 by joichiro (2013-10-18 03:04:16+00:00)
Title: Code Object Model

Work on a prototype object model (Abstract Syntax Tree) for the code used during parsing, optimization, compilation, etc. The code to represent is that of the D language.

Questions to answer
- Should class or struct be used?
- How can the various storage needs of the terminals be accomodated?
- Can Variant be avoided? Is it really that inefficient?
- Is it possible to avoid memory allocation by avoiding usage of objects to represent syntax elements?

The best design will avoid memory allocation as much as possible while still providing the necessary information for optimization and compilation.

A workable prototype should be able to create arbitrary D code, compile, and execute it at runtime in addition to compilation time.