[PATCH 4 of 4] revset: added lazyset implementation to extra revset

Lucas Moscovicz lmoscovicz at fb.com
Wed Feb 12 12:02:35 CST 2014


# HG changeset patch
# User Lucas Moscovicz <lmoscovicz at fb.com>
# Date 1391704571 28800
#      Thu Feb 06 08:36:11 2014 -0800
# Node ID 74e1958b997d3f6eb6d698b39c1256b8c4444630
# Parent  90e180dce71d252f438f9dc9405e3c69687bb48e
revset: added lazyset implementation to extra revset

diff --git a/mercurial/revset.py b/mercurial/revset.py
--- a/mercurial/revset.py
+++ b/mercurial/revset.py
@@ -708,7 +708,7 @@
         extra = repo[r].extra()
         return label in extra and (value is None or matcher(extra[label]))
 
-    return baseset([r for r in subset if _matchvalue(r)])
+    return lazyset(subset, lambda r: _matchvalue(r))
 
 def filelog(repo, subset, x):
     """``filelog(pattern)``


More information about the Mercurial-devel mailing list