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/aifc.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/aifc.py')
-rw-r--r-- | Lib/aifc.py | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/Lib/aifc.py b/Lib/aifc.py index e28c5c0..bc82f48 100644 --- a/Lib/aifc.py +++ b/Lib/aifc.py @@ -453,7 +453,7 @@ class Aifc_read: kludge = 0 if chunk.chunksize == 18: kludge = 1 - print 'Warning: bad COMM chunk size' + print('Warning: bad COMM chunk size') chunk.chunksize = 23 #DEBUG end self._comptype = chunk.read(4) @@ -518,11 +518,11 @@ class Aifc_read: # a position 0 and name '' self._markers.append((id, pos, name)) except EOFError: - print 'Warning: MARK chunk contains only', - print len(self._markers), - if len(self._markers) == 1: print 'marker', - else: print 'markers', - print 'instead of', nmarkers + print('Warning: MARK chunk contains only', end=' ') + print(len(self._markers), end=' ') + if len(self._markers) == 1: print('marker', end=' ') + else: print('markers', end=' ') + print('instead of', nmarkers) class Aifc_write: # Variables used in this class: @@ -939,16 +939,16 @@ if __name__ == '__main__': sys.argv.append('/usr/demos/data/audio/bach.aiff') fn = sys.argv[1] f = open(fn, 'r') - print "Reading", fn - print "nchannels =", f.getnchannels() - print "nframes =", f.getnframes() - print "sampwidth =", f.getsampwidth() - print "framerate =", f.getframerate() - print "comptype =", f.getcomptype() - print "compname =", f.getcompname() + print("Reading", fn) + print("nchannels =", f.getnchannels()) + print("nframes =", f.getnframes()) + print("sampwidth =", f.getsampwidth()) + print("framerate =", f.getframerate()) + print("comptype =", f.getcomptype()) + print("compname =", f.getcompname()) if sys.argv[2:]: gn = sys.argv[2] - print "Writing", gn + print("Writing", gn) g = open(gn, 'w') g.setparams(f.getparams()) while 1: @@ -958,4 +958,4 @@ if __name__ == '__main__': g.writeframes(data) g.close() f.close() - print "Done." + print("Done.") |