[PATCH 1 of 3 V4] revset: record if a set is in topographical order
Yuya Nishihara
yuya at tcha.org
Tue Jun 14 11:37:28 EDT 2016
On Tue, 14 Jun 2016 11:29:11 +0100, Martijn Pieters wrote:
> # HG changeset patch
> # User Martijn Pieters <mjpieters at fb.com>
> # Date 1465898736 -3600
> # Tue Jun 14 11:05:36 2016 +0100
> # Node ID 99d323953b81516541cbdd0898e9bc1017eb9e28
> # Parent c27dc3c31222c7f74331221a3d25566146feecac
> revset: record if a set is in topographical order
Queued the series with trivial typo fixed, thanks.
> diff --git a/mercurial/cmdutil.py b/mercurial/cmdutil.py
> --- a/mercurial/cmdutil.py
> +++ b/mercurial/cmdutil.py
> @@ -2147,7 +2147,7 @@
> if opts.get('rev'):
> # User-specified revs might be unsorted, but don't sort before
> # _makelogrevset because it might depend on the order of revs
> - if not revs.isdescending():
> + if not (revs.isdescending() or revs.istopo()):
> revs.sort(reverse=True)
> if expr:
> # Revset matchers often operate faster on revisions in changelog
You'll need to stop sorting in "if expr" after my patches are landed. I'm
fixing the issue of unstable ordering.
More information about the Mercurial-devel
mailing list