May 2012
·
16 Reads
Code generators are metaprograms translating a regular tree to a sentence of a context-free language. The metalanguage used to implement the code generator should be, on the one side, expressive enough to be of practical value, and, on the other side, restricted enough to enforce the separation between the view and the model, according to the model-viewcontroller architecture (MVC). In the MVC architecture, templates are commonly used to implement the view of the internal data of an application (model).