Patchwork D897: context: rename local 'attr' to 'attr_'

login
register
mail settings
Submitter phabricator
Date Oct. 2, 2017, 5:23 p.m.
Message ID <298b2c01f7d94af3542e4877657e615f@localhost.localdomain>
Download mbox | patch
Permalink /patch/24402/
State Not Applicable
Headers show

Comments

phabricator - Oct. 2, 2017, 5:23 p.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG52e9310626a8: context: rename local &#039;attr&#039; to &#039;attr_&#039; (authored by sid0, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D897?vs=2318&id=2339

REVISION DETAIL
  https://phab.mercurial-scm.org/D897

AFFECTED FILES
  mercurial/context.py

CHANGE DETAILS




To: sid0, #hg-reviewers, indygreg
Cc: indygreg, mercurial-devel

Patch

diff --git a/mercurial/context.py b/mercurial/context.py
--- a/mercurial/context.py
+++ b/mercurial/context.py
@@ -2420,9 +2420,9 @@ 
         if reusable:
             # copy extra fields from originalfctx
             attrs = ['rawdata', 'rawflags', '_filenode', '_filerev']
-            for attr in attrs:
-                if util.safehasattr(originalfctx, attr):
-                    setattr(self, attr, getattr(originalfctx, attr))
+            for attr_ in attrs:
+                if util.safehasattr(originalfctx, attr_):
+                    setattr(self, attr_, getattr(originalfctx, attr_))
 
     def data(self):
         return self._datafunc()