Refactor on compiler class