[PATCH 2 of 8 STABLE] revset: fix revision filtering in spanset.contains (regression)
pierre-yves.david at ens-lyon.org
pierre-yves.david at ens-lyon.org
Tue Apr 29 00:48:29 UTC 2014
# HG changeset patch
# User Pierre-Yves David <pierre-yves.david at fb.com>
# Date 1398727732 25200
# Mon Apr 28 16:28:52 2014 -0700
# Branch stable
# Node ID 3a33cd29d255c49d03a3ec9d63b48b6622941c5b
# Parent 80f58cb63468525ff8a3f17536608e307bdb26ca
revset: fix revision filtering in spanset.contains (regression)
The argument is `x` but the variable tested for filtering is `rev`. `rev`
happens to be a revset methods, ... never part of the filtered revs. This
method is now using `rev` for everything.
diff --git a/mercurial/revset.py b/mercurial/revset.py
--- a/mercurial/revset.py
+++ b/mercurial/revset.py
@@ -2780,12 +2780,12 @@ class spanset(_orderedsetmixin):
yield r
else:
for r in iterrange:
yield r
- def __contains__(self, x):
- return self._contained(x) and not (self._hiddenrevs and rev in
+ def __contains__(self, rev):
+ return self._contained(rev) and not (self._hiddenrevs and rev in
self._hiddenrevs)
def __nonzero__(self):
for r in self:
return True
More information about the Mercurial-devel
mailing list