Compiling first step to simplify template mechanisms
Finishes refactoring of applyTemplate in Parser