[PATCH 1 of 2 V2] revset: use smartset minus operator

Yuya Nishihara yuya at tcha.org
Wed Feb 24 10:21:23 EST 2016


On Tue, 23 Feb 2016 21:54:53 +0000, Durham Goode wrote:
> Taking a minus operator, then converting it to "and-not", then converting it
> back to minus just seems strange.  I can see people screwing up minus
> operator perf while trying to improve 'and' performance and not even
> realizing it.  Seems cleaner to just let minus be minus and be done with it.

I prefer Martin's patch. A minus operator is just a shorthand for "and not". If
we have a fast path for "x and not y", it should be optimized as well.

Optimizing only "op == 'minus'" case would imply that it cannot be applied to
a general "and not" form.


More information about the Mercurial-devel mailing list