changeset 9928:a92539567ef3

findrenames: improve coding-style
author Benoit Boissinot <benoit.boissinot@ens-lyon.org>
date Tue, 24 Nov 2009 20:40:04 +0100
parents 2ae4d0865629
children 193a8d539e21
files mercurial/cmdutil.py
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/cmdutil.py	Tue Nov 24 18:21:47 2009 +0100
+++ b/mercurial/cmdutil.py	Tue Nov 24 20:40:04 2009 +0100
@@ -290,18 +290,19 @@
             equal = 0
             alines = mdiff.splitnewlines(text)
             matches = bdiff.blocks(text, orig)
-            for x1,x2,y1,y2 in matches:
+            for x1, x2, y1, y2 in matches:
                 for line in alines[x1:x2]:
                     equal += len(line)
 
             lengths = len(text) + len(orig)
-            return equal*2.0 / lengths
+            return equal * 2.0 / lengths
 
         for a in added:
             bestscore = copies.get(a, (None, threshold))[1]
             myscore = score(repo.wread(a))
             if myscore >= bestscore:
                 copies[a] = (r, myscore)
+
     for dest, v in copies.iteritems():
         source, score = v
         yield source, dest, score