Modification to generation code