[pypy-commit] pyrepl py3ksupport: add unicode alias to unix_console

RonnyPfannschmidt noreply at buildbot.pypy.org
Tue Nov 8 00:13:14 CET 2011


Author: Ronny Pfannschmidt <Ronny.Pfannschmidt at gmx.de>
Branch: py3ksupport
Changeset: r155:9adc0ebfa532
Date: 2011-11-08 00:13 +0100
http://bitbucket.org/pypy/pyrepl/changeset/9adc0ebfa532/

Log:	add unicode alias to unix_console

diff --git a/pyrepl/unix_console.py b/pyrepl/unix_console.py
--- a/pyrepl/unix_console.py
+++ b/pyrepl/unix_console.py
@@ -30,6 +30,10 @@
 class InvalidTerminal(RuntimeError):
     pass
 
+try:
+    unicode
+except NameError:
+    unicode = str
 
 _error = (termios.error, curses.error, InvalidTerminal)
 


More information about the pypy-commit mailing list