Remove dumb CodeBlock duplication in the emitters.
Fixes issue 6990.
This uses a bit of templating to remove the duplicate code that is the CodeBlocks in each emitter headers.
No actual functionality change in this.
Merge pull request #253 from Sonicadvance1/CodeBlock-dedup

Remove dumb CodeBlock duplication in the emitters.