[Python-checkins] cpython (2.7): Update int division to quiet 2to3 warning.

terry.reedy python-checkins at python.org
Sun Jul 28 02:29:15 CEST 2013


http://hg.python.org/cpython/rev/38d47ac7fc2d
changeset:   84872:38d47ac7fc2d
branch:      2.7
user:        Terry Jan Reedy <tjreedy at udel.edu>
date:        Sat Jul 27 20:28:53 2013 -0400
summary:
  Update int division to quiet 2to3 warning.

files:
  Lib/lib-tk/test/test_ttk/test_widgets.py |  4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)


diff --git a/Lib/lib-tk/test/test_ttk/test_widgets.py b/Lib/lib-tk/test/test_ttk/test_widgets.py
--- a/Lib/lib-tk/test/test_ttk/test_widgets.py
+++ b/Lib/lib-tk/test/test_ttk/test_widgets.py
@@ -26,8 +26,8 @@
     def test_identify(self):
         self.widget.update_idletasks()
         self.assertEqual(self.widget.identify(
-            int(self.widget.winfo_width() / 2),
-            int(self.widget.winfo_height() / 2)
+            self.widget.winfo_width() // 2,
+            self.widget.winfo_height() // 2
             ), "label")
         self.assertEqual(self.widget.identify(-1, -1), "")
 

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list