interchange two steps in compile()