summaryrefslogtreecommitdiffstats
path: root/Objects
diff options
context:
space:
mode:
authorRaymond Hettinger <python@rcn.com>2002-05-21 15:14:57 (GMT)
committerRaymond Hettinger <python@rcn.com>2002-05-21 15:14:57 (GMT)
commit0ebac97058baad8250adf710f287e8fb8770f7fa (patch)
treedd3fc141f0414e3dba41fb11434be6f8c9d6f35b /Objects
parent5ecb7aaa6a6e8ee60e81831da1a15514e59f4489 (diff)
downloadcpython-0ebac97058baad8250adf710f287e8fb8770f7fa.zip
cpython-0ebac97058baad8250adf710f287e8fb8770f7fa.tar.gz
cpython-0ebac97058baad8250adf710f287e8fb8770f7fa.tar.bz2
Patch 549187. Improve string formatting error message.
Diffstat (limited to 'Objects')
-rw-r--r--Objects/stringobject.c4
-rw-r--r--Objects/unicodeobject.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/Objects/stringobject.c b/Objects/stringobject.c
index 6c18add..668668c 100644
--- a/Objects/stringobject.c
+++ b/Objects/stringobject.c
@@ -3628,7 +3628,7 @@ PyString_Format(PyObject *format, PyObject *args)
}
if (dict && (argidx < arglen) && c != '%') {
PyErr_SetString(PyExc_TypeError,
- "not all arguments converted");
+ "not all arguments converted during string formatting");
goto error;
}
Py_XDECREF(temp);
@@ -3636,7 +3636,7 @@ PyString_Format(PyObject *format, PyObject *args)
} /* until end */
if (argidx < arglen && !dict) {
PyErr_SetString(PyExc_TypeError,
- "not all arguments converted");
+ "not all arguments converted during string formatting");
goto error;
}
if (args_owned) {
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c
index 9a3e456..5cc8455 100644
--- a/Objects/unicodeobject.c
+++ b/Objects/unicodeobject.c
@@ -5708,7 +5708,7 @@ PyObject *PyUnicode_Format(PyObject *format,
}
if (dict && (argidx < arglen) && c != '%') {
PyErr_SetString(PyExc_TypeError,
- "not all arguments converted");
+ "not all arguments converted during string formatting");
goto onError;
}
Py_XDECREF(temp);
@@ -5716,7 +5716,7 @@ PyObject *PyUnicode_Format(PyObject *format,
} /* until end */
if (argidx < arglen && !dict) {
PyErr_SetString(PyExc_TypeError,
- "not all arguments converted");
+ "not all arguments converted during string formatting");
goto onError;
}