Refactoring instructions into enum