--- a/mercurial/util.py Thu Sep 06 11:33:40 2018 -0700
+++ b/mercurial/util.py Thu Sep 06 11:37:27 2018 -0700
@@ -1241,7 +1241,7 @@
head.prev = head
head.next = head
self._size = 1
- self._capacity = max
+ self.capacity = max
def __len__(self):
return len(self._cache)
@@ -1269,7 +1269,7 @@
self._movetohead(node)
return
- if self._size < self._capacity:
+ if self._size < self.capacity:
node = self._addcapacity()
else:
# Grab the last/oldest item.
@@ -1312,7 +1312,7 @@
self._cache.clear()
def copy(self):
- result = lrucachedict(self._capacity)
+ result = lrucachedict(self.capacity)
# We copy entries by iterating in oldest-to-newest order so the copy
# has the correct ordering.