Use some more disciplined token macros, refactor to conform.
More refactoring of equivalences, C++ generation rules.