Anonymous avatar Anonymous committed aef7e82

Convert old-style classes in bench/* scripts to new-style classes.

Comments (0)

Files changed (4)

bench/dependency-func.py

 #       {'keyword' : 'arguments'},
 #   ),
 
-class A:
+class A(object):
     pass
 
 Data = [

bench/env.__setitem__.py

 # These wrap the basic timeit function to make it a little more
 # convenient to do side-by-side tests of code.
 
-class Timing:
+class Timing(object):
     def __init__(self, name, num, init, statement):
         self.__timer = timeit.Timer(statement, init)
         self.__num   = num
 # After we're done should be the one that shows up at the top of the
 # list as we run our timings.
 
-class Environment:
+class Environment(object):
     _special_set = {
         'BUILDERS' : None,
         'SCANNERS' : None,

bench/is_types.py

 #       {'keyword' : 'arguments'},
 #   ),
 
-class A:
+class A(object):
     pass
 
 Data = [
 try:
     import gc
 except ImportError:
-    class _fake_gc:
+    class _fake_gc(object):
         def isenabled(self):
             return None
         def enable(self):
     """Helper to reindent a multi-line statement."""
     return src.replace("\n", "\n" + " "*indent)
 
-class Timer:
+class Timer(object):
     """Class for timing execution speed of small code snippets.
 
     The constructor takes a statement to be timed, an additional
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.