[SuperSize] Modernize syntax for int divisions and exception variable assignments.
To aid in porting SuperSize to Python 3, this CL does the following: * Sort out int vs. float divisions. * Add "'from __future__ import division" to each python file (except mock files for testing). * For int division: Use "//" (was "/") * For float division: Ensure this can be inferred, by using float(), or float constants (e.g., 1024.0). * Change "except" variable assignment style. * Use "except Exception as e" (was "except Exception, e"). Bug: 1054018 Change-Id: I25925196fe33fc7f4ca28f126f180eb4060fa2b2 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2094544 Commit-Queue: Samuel Huang <huangs@chromium.org> Reviewed-by:Andrew Grieve <agrieve@chromium.org> Cr-Commit-Position: refs/heads/master@{#748375}
Showing
Please register or sign in to comment