improve generated code formatting