Cosmetics: more function reordering