Minor fixes to Generator