Code generation

Auto code generation is working under the simple tests that I'm using.