first (not tested) verion of our templates compiler