changeset 25129:40a2cf1c765b

revset: drop redundant filteredset from right-hand side set of "or" operation Since 5548f558db3d, it should no longer be necessary because the addset can remove duplicates correctly.
author Yuya Nishihara <yuya@tcha.org>
date Mon, 30 Mar 2015 20:56:37 +0900
parents 631766d1f57a
children a94ef7f517e0
files mercurial/revset.py tests/test-revset.t
diffstat 2 files changed, 4 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/revset.py	Sun May 10 05:11:13 2015 -0700
+++ b/mercurial/revset.py	Mon Mar 30 20:56:37 2015 +0900
@@ -360,7 +360,7 @@
 
 def orset(repo, subset, x, y):
     xl = getset(repo, subset, x)
-    yl = getset(repo, subset - xl, y)
+    yl = getset(repo, subset, y)
     return xl + yl
 
 def notset(repo, subset, x):
--- a/tests/test-revset.t	Sun May 10 05:11:13 2015 -0700
+++ b/tests/test-revset.t	Mon Mar 30 20:56:37 2015 +0900
@@ -889,9 +889,7 @@
   * set:
   <addset
     <baseset [5, 3, 1]>,
-    <filteredset
-      <filteredset
-        <fullreposet+ 0:9>>>>
+    <generatorset+>>
   5
   3
   1
@@ -913,8 +911,7 @@
   * set:
   <addset+
     <generatorset+>,
-    <filteredset
-      <baseset [5, 3, 1]>>>
+    <baseset [5, 3, 1]>>
   0
   1
   2
@@ -1432,8 +1429,7 @@
   <addset
     <baseset [9]>,
     <filteredset
-      <filteredset
-        <fullreposet+ 0:9>>>>
+      <fullreposet+ 0:9>>>
   9
 
   $ try 'd(2:5)'