# HG changeset patch # User Pierre-Yves David # Date 1412295723 18000 # Node ID f7b0ebe6ad422254b31d6b5ccb8c4c544e404334 # Parent bf5ff3686100e565ba9eebe505e9b125da1a8581 abstractsmartset: add default implementation for __add__ diff -r bf5ff3686100 -r f7b0ebe6ad42 mercurial/revset.py --- a/mercurial/revset.py Thu Oct 02 19:21:40 2014 -0500 +++ b/mercurial/revset.py Thu Oct 02 19:22:03 2014 -0500 @@ -2280,7 +2280,12 @@ """Returns a new object with the union of the two collections. This is part of the mandatory API for smartset.""" - raise NotImplementedError() + kwargs = {} + if self.isascending() and other.isascending(): + kwargs['ascending'] = True + if self.isdescending() and other.isdescending(): + kwargs['ascending'] = False + return _addset(self, other, **kwargs) def __sub__(self, other): """Returns a new object with the substraction of the two collections.