revset: fix crash by repo.revs('%d', tip + 1)
IndexError shouldn't be raised from a revset predicate. The error message
is copied from scmutil.revsymbol().
revset: allow repo.revs('%d', wdirrev)
Otherwise we can't write repo.revs('null:%d', subset.max()) to build
a smartset covering the range {null .. tip} + {wdir} if subset includes
wdir.