diff options
author | Guido van Rossum <guido@python.org> | 2007-02-09 05:37:30 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2007-02-09 05:37:30 (GMT) |
commit | be19ed77ddb047e02fe94d142181062af6d99dcc (patch) | |
tree | 70f214e06554046fcccbadeb78665f25e07ce965 /Lib/test/test_compiler.py | |
parent | 452bf519a70c3db0e7f0d2540b1bfb07d9085583 (diff) | |
download | cpython-be19ed77ddb047e02fe94d142181062af6d99dcc.zip cpython-be19ed77ddb047e02fe94d142181062af6d99dcc.tar.gz cpython-be19ed77ddb047e02fe94d142181062af6d99dcc.tar.bz2 |
Fix most trivially-findable print statements.
There's one major and one minor category still unfixed:
doctests are the major category (and I hope to be able to augment the
refactoring tool to refactor bona fide doctests soon);
other code generating print statements in strings is the minor category.
(Oh, and I don't know if the compiler package works.)
Diffstat (limited to 'Lib/test/test_compiler.py')
-rw-r--r-- | Lib/test/test_compiler.py | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/Lib/test/test_compiler.py b/Lib/test/test_compiler.py index 7320368..ab9a660 100644 --- a/Lib/test/test_compiler.py +++ b/Lib/test/test_compiler.py @@ -30,8 +30,7 @@ class CompilerTest(unittest.TestCase): # Print still working message since this test can be really slow if next_time <= time.time(): next_time = time.time() + _PRINT_WORKING_MSG_INTERVAL - print >>sys.__stdout__, \ - ' testCompileLibrary still working, be patient...' + print(' testCompileLibrary still working, be patient...', file=sys.__stdout__) sys.__stdout__.flush() if not basename.endswith(".py"): @@ -40,7 +39,7 @@ class CompilerTest(unittest.TestCase): continue path = os.path.join(dir, basename) if test.test_support.verbose: - print "compiling", path + print("compiling", path) f = open(path, "U") buf = f.read() f.close() @@ -94,7 +93,7 @@ class CompilerTest(unittest.TestCase): try: self._check_lineno(node) except AssertionError: - print node.__class__, node.lineno + print(node.__class__, node.lineno) raise def _check_lineno(self, node): @@ -217,7 +216,7 @@ else: a, b = b, a try: - print yo + print(yo) except: yo = 3 else: |