Use macros to implement ord for group candidates.