generatorset: implement isascending and isdescending
authorPierre-Yves David <pierre-yves.david@fb.com>
Sat, 04 Oct 2014 06:17:18 -0700
changeset 22801 6af9e9b6af39
parent 22800 29a8c20e14a8
child 22802 1fcd361efaf4
generatorset: implement isascending and isdescending
mercurial/revset.py
--- a/mercurial/revset.py	Fri Oct 03 21:11:56 2014 -0700
+++ b/mercurial/revset.py	Sat Oct 04 06:17:18 2014 -0700
@@ -2739,6 +2739,12 @@
     def reverse(self):
         self._ascending = not self._ascending
 
+    def isascending(self):
+        return self._ascending
+
+    def isdescending(self):
+        return not self._ascending
+
 def spanset(repo, start=None, end=None):
     """factory function to dispatch between fullreposet and actual spanset