Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/revset.py @ 13873:02c3d4d44a92
revset: teach optimizer that closed is slowish
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Mon, 04 Apr 2011 14:21:54 -0500 |
parents | 7eb82f88e157 |
children | a8d13ee0ce68 |
comparison
equal
deleted
inserted
replaced
13872:e6bd5b403de0 | 13873:02c3d4d44a92 |
---|---|
806 wb, tb = optimize(x[2], small) | 806 wb, tb = optimize(x[2], small) |
807 return wa + wb, (op, ta, tb) | 807 return wa + wb, (op, ta, tb) |
808 elif op == 'func': | 808 elif op == 'func': |
809 f = getstring(x[1], _("not a symbol")) | 809 f = getstring(x[1], _("not a symbol")) |
810 wa, ta = optimize(x[2], small) | 810 wa, ta = optimize(x[2], small) |
811 if f in "grep date user author keyword branch file outgoing": | 811 if f in "grep date user author keyword branch file outgoing closed": |
812 w = 10 # slow | 812 w = 10 # slow |
813 elif f in "modifies adds removes": | 813 elif f in "modifies adds removes": |
814 w = 30 # slower | 814 w = 30 # slower |
815 elif f == "contains": | 815 elif f == "contains": |
816 w = 100 # very slow | 816 w = 100 # very slow |