Patchwork D2337: py3: make sure we are doing integer division by using '//'

login
register
mail settings
Submitter phabricator
Date Feb. 18, 2018, 8:46 p.m.
Message ID <0eaa73c2809561471cf4d4cf8dd17135@localhost.localdomain>
Download mbox | patch
Permalink /patch/28124/
State Not Applicable
Headers show

Comments

phabricator - Feb. 18, 2018, 8:46 p.m.
This revision was automatically updated to reflect the committed changes.
Closed by commit rHG74f40bdc06bd: py3: make sure we are doing integer division by using &#039;//&#039; (authored by pulkit, committed by ).

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D2337?vs=5891&id=5894

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

AFFECTED FILES
  mercurial/crecord.py

CHANGE DETAILS




To: pulkit, #hg-reviewers, durin42
Cc: mercurial-devel

Patch

diff --git a/mercurial/crecord.py b/mercurial/crecord.py
--- a/mercurial/crecord.py
+++ b/mercurial/crecord.py
@@ -1335,7 +1335,7 @@ 
         # temporarily disable printing to windows by printstring
         patchdisplaystring = self.printitem(item, ignorefolding,
                                             recursechildren, towin=False)
-        numlines = len(patchdisplaystring) / self.xscreensize
+        numlines = len(patchdisplaystring) // self.xscreensize
         return numlines
 
     def sigwinchhandler(self, n, frame):