Correctly skip function body in extensions, not just classes.
We now output generated code to a header and C source file, no longer to stdout.