index: use index.get_rev in revset._mapbynodefunc
We slightly update the code in the process.
Differential Revision: https://phab.mercurial-scm.org/D7343