Patchwork [2,of,4] manifestdict._intersectfiles: avoid one level of property indirection

login
register
mail settings
Submitter Martin von Zweigbergk
Date April 8, 2015, 7:58 p.m.
Message ID <12c2a79698df71be5823.1428523083@martinvonz.mtv.corp.google.com>
Download mbox | patch
Permalink /patch/8565/
State Accepted
Headers show

Comments

Martin von Zweigbergk - April 8, 2015, 7:58 p.m.
# HG changeset patch
# User Martin von Zweigbergk <martinvonz@google.com>
# Date 1428512639 25200
#      Wed Apr 08 10:03:59 2015 -0700
# Node ID 12c2a79698df71be5823331cac70bfc8b042a88b
# Parent  a9025c400317d9cb93f0afa58ff3e4679812ec27
manifestdict._intersectfiles: avoid one level of property indirection

We have already bothered to extract "lm = self._lm", so let's use "lm"
where possible.

Patch

diff -r a9025c400317 -r 12c2a79698df mercurial/manifest.py
--- a/mercurial/manifest.py	Wed Apr 08 10:06:05 2015 -0700
+++ b/mercurial/manifest.py	Wed Apr 08 10:03:59 2015 -0700
@@ -206,7 +206,7 @@ 
         lm = self._lm
         for fn in files:
             if fn in lm:
-                ret._lm[fn] = self._lm[fn]
+                ret._lm[fn] = lm[fn]
         return ret
 
     def filesnotin(self, m2):