revpair: do not optimize tree to check for odd-range spec
At
cc3a30ff9490, we had to optimize a parsed tree to resolve x^:y ambiguity.
Since we've moved the resolution of x^:y to parse(), we no longer have to call
optimize(). Therefore, (x:y) can be taken as a single expression, not an odd
range expression x:y.
#require test-repo pyflakes hg10
$ . "$TESTDIR/helpers-testrepo.sh"
$ cd "`dirname "$TESTDIR"`"
run pyflakes on all tracked files ending in .py or without a file ending
(skipping binary file random-seed)
$ hg locate 'set:**.py or grep("^#!.*python")' \
> -X mercurial/pycompat.py \
> 2>/dev/null \
> | xargs pyflakes 2>/dev/null | "$TESTDIR/filterpyflakes.py"
tests/filterpyflakes.py:61: undefined name 'undefinedname'