From: Eli Bendersky Date: Fri, 22 Jul 2011 11:39:55 +0000 (+0300) Subject: Issue #12434: make StringIO.write error message consistent with Python 2.7 nomenclature X-Git-Tag: v2.7.3rc1~589 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=eaf312a0a45a8713d001ae4957366440f414e1a8;p=thirdparty%2FPython%2Fcpython.git Issue #12434: make StringIO.write error message consistent with Python 2.7 nomenclature --- diff --git a/Modules/_io/stringio.c b/Modules/_io/stringio.c index cf0f8b15a6c7..e3de75155d07 100644 --- a/Modules/_io/stringio.c +++ b/Modules/_io/stringio.c @@ -464,7 +464,7 @@ stringio_write(stringio *self, PyObject *obj) CHECK_INITIALIZED(self); if (!PyUnicode_Check(obj)) { - PyErr_Format(PyExc_TypeError, "string argument expected, got '%s'", + PyErr_Format(PyExc_TypeError, "unicode argument expected, got '%s'", Py_TYPE(obj)->tp_name); return NULL; }