reorder cases in switches