Author: Amaury Forgeot d'Arc <[email protected]>
Branch: py3k
Changeset: r50651:95d16ee05f34
Date: 2011-12-18 13:08 +0100
http://bitbucket.org/pypy/pypy/changeset/95d16ee05f34/
Log: Syntax fixes for "import readline"
diff --git a/lib_pypy/pyrepl/unix_console.py b/lib_pypy/pyrepl/unix_console.py
--- a/lib_pypy/pyrepl/unix_console.py
+++ b/lib_pypy/pyrepl/unix_console.py
@@ -407,7 +407,7 @@
self.partial_char += char
try:
c = unicode(self.partial_char, self.encoding)
- except UnicodeError, e:
+ except UnicodeError as e:
if len(e.args) > 4 and \
e.args[4] == 'unexpected end of data':
pass
@@ -427,7 +427,7 @@
while 1: # All hail Unix!
try:
self.push_char(os.read(self.input_fd, 1))
- except (IOError, OSError), err:
+ except (IOError, OSError) as err:
if err.errno == errno.EINTR:
if not self.event_queue.empty():
return self.event_queue.get()
_______________________________________________
pypy-commit mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-commit