--- a/mercurial/sparse.py Thu Jul 06 14:53:08 2017 -0700
+++ b/mercurial/sparse.py Thu Jul 06 16:10:28 2017 -0700
@@ -134,9 +134,6 @@
return profiles
-def invalidatesignaturecache(repo):
- repo._sparsesignaturecache.clear()
-
def configsignature(repo, includetemp=True):
"""Obtain the signature string for the current sparse configuration.
@@ -180,7 +177,7 @@
fh.write(e)
fh.write('\n')
- invalidatesignaturecache(repo)
+ repo._sparsesignaturecache.clear()
def readtemporaryincludes(repo):
raw = repo.vfs.tryread('tempsparse')
@@ -191,7 +188,7 @@
def writetemporaryincludes(repo, includes):
repo.vfs.write('tempsparse', '\n'.join(sorted(includes)))
- invalidatesignaturecache(repo)
+ repo._sparsesignaturecache.clear()
def addtemporaryincludes(repo, additional):
includes = readtemporaryincludes(repo)
@@ -229,7 +226,7 @@
dirstate.drop(file)
repo.vfs.unlink('tempsparse')
- invalidatesignaturecache(repo)
+ repo._sparsesignaturecache.clear()
msg = _('cleaned up %d temporarily added file(s) from the '
'sparse checkout\n')
repo.ui.status(msg % len(tempincludes))