changeset 35837:d8f891ec5d7d

obsolete: use native string when peeking in __dict__ # skip-blame just an r prefix on a few string literals Differential Revision: https://phab.mercurial-scm.org/D1896
author Augie Fackler <augie@google.com>
date Wed, 17 Jan 2018 21:46:09 -0500
parents d4e5b2653693
children f484b9d95c23
files mercurial/obsolete.py
diffstat 1 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/obsolete.py	Wed Jan 17 21:45:15 2018 -0500
+++ b/mercurial/obsolete.py	Wed Jan 17 21:46:09 2018 -0500
@@ -570,7 +570,7 @@
         return len(self._all)
 
     def __nonzero__(self):
-        if not self._cached('_all'):
+        if not self._cached(r'_all'):
             try:
                 return self.svfs.stat('obsstore').st_size > 1
             except OSError as inst:
@@ -727,11 +727,11 @@
         markers = list(markers) # to allow repeated iteration
         self._data = self._data + rawdata
         self._all.extend(markers)
-        if self._cached('successors'):
+        if self._cached(r'successors'):
             _addsuccessors(self.successors, markers)
-        if self._cached('predecessors'):
+        if self._cached(r'predecessors'):
             _addpredecessors(self.predecessors, markers)
-        if self._cached('children'):
+        if self._cached(r'children'):
             _addchildren(self.children, markers)
         _checkinvalidmarkers(markers)