Fixed some additional errors in the code generation.