remove duplicate code statements for Element generation from xtext