changeset 34431:52e9310626a8

context: rename local 'attr' to 'attr_' In the next diff we're going to import mercurial.thirdparty.attr, and pyflakes complains about this if this rename isn't done. Differential Revision: https://phab.mercurial-scm.org/D897
author Siddharth Agarwal <sid0@fb.com>
date Mon, 02 Oct 2017 02:34:47 -0700
parents 80215865d154
children 2e32c6a31cc7
files mercurial/context.py
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/context.py	Mon Oct 02 02:34:47 2017 -0700
+++ b/mercurial/context.py	Mon Oct 02 02:34:47 2017 -0700
@@ -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()