Fixed codegen