##// END OF EJS Templates
localrepo: optimize internode status calls using match.always...
Jesse Glick -
r16645:9a21fc2c default
parent child Browse files
Show More
@@ -1333,6 +1333,8 b' class localrepository(repo.repository):'
1333 1333
1334 1334 def mfmatches(ctx):
1335 1335 mf = ctx.manifest().copy()
1336 if match.always():
1337 return mf
1336 1338 for fn in mf.keys():
1337 1339 if not match(fn):
1338 1340 del mf[fn]
@@ -118,6 +118,8 b' class match(object):'
118 118 return self._files
119 119 def anypats(self):
120 120 return self._anypats
121 def always(self):
122 return False
121 123
122 124 class exact(match):
123 125 def __init__(self, root, cwd, files):
@@ -126,6 +128,8 b' class exact(match):'
126 128 class always(match):
127 129 def __init__(self, root, cwd):
128 130 match.__init__(self, root, cwd, [])
131 def always(self):
132 return True
129 133
130 134 class narrowmatcher(match):
131 135 """Adapt a matcher to work on a subdirectory only.
General Comments 0
You need to be logged in to leave comments. Login now