fix issues on compiler pass