Mercurial > public > mercurial-scm > hg
diff mercurial/scmutil.py @ 29771:98976e3cae57
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.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sat, 06 Aug 2016 20:46:53 +0900 |
parents | 2372182e505b |
children | 35560189677c |
line wrap: on
line diff
--- a/mercurial/scmutil.py Sat Aug 06 20:37:48 2016 +0900 +++ b/mercurial/scmutil.py Sat Aug 06 20:46:53 2016 +0900 @@ -781,7 +781,6 @@ def _pairspec(revspec): tree = revset.parse(revspec) - tree = revset.optimize(tree) # fix up "x^:y" -> "(x^):y" return tree and tree[0] in ('range', 'rangepre', 'rangepost', 'rangeall') def revpair(repo, revs):