revset: added lazyset implementation to closed revset
authorLucas Moscovicz <lmoscovicz@fb.com>
Thu, 06 Feb 2014 08:31:55 -0800
changeset 20479 c38e5556d87b
parent 20478 80628d4069be
child 20480 ada89e5b5b0c
revset: added lazyset implementation to closed revset
mercurial/revset.py
--- a/mercurial/revset.py	Fri Jan 31 01:12:35 2014 -0800
+++ b/mercurial/revset.py	Thu Feb 06 08:31:55 2014 -0800
@@ -522,7 +522,7 @@
     """
     # i18n: "closed" is a keyword
     getargs(x, 0, 0, _("closed takes no arguments"))
-    return baseset([r for r in subset if repo[r].closesbranch()])
+    return lazyset(subset, lambda r: repo[r].closesbranch())
 
 def contains(repo, subset, x):
     """``contains(pattern)``