summaryrefslogtreecommitdiffstats
path: root/Lib/py_compile.py
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2001-02-09 08:56:30 (GMT)
committerEric S. Raymond <esr@thyrsus.com>2001-02-09 08:56:30 (GMT)
commit6b71e747b19c41e0665ee14eb755c924a40dd774 (patch)
treeba208a6616870c43672678ad07b772435aef6fa0 /Lib/py_compile.py
parent141971f22a1269e782b1481779f766629ac83afc (diff)
downloadcpython-6b71e747b19c41e0665ee14eb755c924a40dd774.zip
cpython-6b71e747b19c41e0665ee14eb755c924a40dd774.tar.gz
cpython-6b71e747b19c41e0665ee14eb755c924a40dd774.tar.bz2
String method conversion.
Diffstat (limited to 'Lib/py_compile.py')
-rw-r--r--Lib/py_compile.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/py_compile.py b/Lib/py_compile.py
index b453109..da3bdaf 100644
--- a/Lib/py_compile.py
+++ b/Lib/py_compile.py
@@ -59,10 +59,10 @@ def compile(file, cfile=None, dfile=None):
try:
codeobject = __builtin__.compile(codestring, dfile or file, 'exec')
except SyntaxError, detail:
- import traceback, sys, string
+ import traceback, sys
lines = traceback.format_exception_only(SyntaxError, detail)
for line in lines:
- sys.stderr.write(string.replace(line, 'File "<string>"',
+ sys.stderr.write(line.replace('File "<string>"',
'File "%s"' % (dfile or file)))
return
if not cfile: