Author: Matti Picus <[email protected]>
Branch: winconsoleio
Changeset: r97523:58e969594b31
Date: 2019-09-18 14:51 +0300
http://bitbucket.org/pypy/pypy/changeset/58e969594b31/

Log:    bad copy paste?

diff --git a/pypy/module/_io/interp_win32consoleio.py 
b/pypy/module/_io/interp_win32consoleio.py
--- a/pypy/module/_io/interp_win32consoleio.py
+++ b/pypy/module/_io/interp_win32consoleio.py
@@ -219,7 +219,7 @@
                 elif char == "r":
                     if rwa:
                         raise oefmt(space.w_ValueError,
-                                "invalid mode: %s", space.text_w(w_mode))
+                                "invalid mode: %s", space.newtext(mode))
                     rwa = True
                     self.readable = True
                     if console_type == "x":
@@ -227,14 +227,14 @@
                 elif char == "w":
                     if rwa:
                         raise oefmt(space.w_ValueError,
-                                "invalid mode: %s", space.text_w(w_mode))
+                                "invalid mode: %s", space.newtext(mode))
                     rwa = True
                     self.writable = True
                     if console_type == 'x':
                         console_type = 'w'
                 else:
                     raise oefmt(space.w_ValueError,
-                                "invalid mode: %s", space.text_w(w_mode))
+                                "invalid mode: %s", space.newtext(mode))
             if not rwa:
                 raise oefmt(space.w_ValueError,
                             "Must have exactly one of read or write mode")
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to