mercurial/logcmdutil.py
changeset 36985 255f635c3204
parent 36926 6ff6e1d6b5b8
child 36991 317382151ac3
--- a/mercurial/logcmdutil.py	Sat Mar 17 21:46:17 2018 -0400
+++ b/mercurial/logcmdutil.py	Sun Mar 11 21:05:29 2018 +0900
@@ -423,7 +423,7 @@
                                          resources=tres,
                                          cache=templatekw.defaulttempl)
         self._counter = itertools.count()
-        self.cache = tres['cache']  # shared with _graphnodeformatter()
+        self._getcache = tres['cache']  # shared with _graphnodeformatter()
 
         self._tref = tmplspec.ref
         self._parts = {'header': '', 'footer': '',
@@ -852,7 +852,8 @@
     spec = templater.unquotestring(spec)
     tres = formatter.templateresources(ui)
     if isinstance(displayer, changesettemplater):
-        tres['cache'] = displayer.cache  # reuse cache of slow templates
+        # reuse cache of slow templates
+        tres['cache'] = displayer._getcache
     templ = formatter.maketemplater(ui, spec, defaults=templatekw.keywords,
                                     resources=tres)
     def formatnode(repo, ctx):