indices sorted before return, see NEWS