Correct codegen with dumpJS on