Mercurial > hg-stable
changeset 21215:717ba2c3c9da stable
orderedlazyset: directly use __contains__ instead of a lambda
We apply the same speedup as in spanset, getting rid of the useless lambda.
(No new timing, as this is the very same change)
author | Pierre-Yves David <pierre-yves.david@fb.com> |
---|---|
date | Thu, 01 May 2014 12:15:28 -0700 |
parents | 0952904dc1e5 |
children | 6d632cf8a811 |
files | mercurial/revset.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/revset.py Thu May 01 12:15:00 2014 -0700 +++ b/mercurial/revset.py Thu May 01 12:15:28 2014 -0700 @@ -2419,7 +2419,7 @@ self.reverse() def __and__(self, x): - return orderedlazyset(self, lambda r: r in x, + return orderedlazyset(self, x.__contains__, ascending=self._ascending) def __sub__(self, x):