Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 914a2ed

Browse files
committed
Improve TypeError exception message for list catenation.
1 parent b6a9ada commit 914a2ed

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Objects/listobject.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -389,8 +389,8 @@ list_concat(a, bb)
389389
PyListObject *np;
390390
if (!PyList_Check(bb)) {
391391
PyErr_Format(PyExc_TypeError,
392-
"can only append list (not \"%.200s\") to list",
393-
bb->ob_type->tp_name);
392+
"can only concatenate list (not \"%.200s\") to list",
393+
bb->ob_type->tp_name);
394394
return NULL;
395395
}
396396
#define b ((PyListObject *)bb)

0 commit comments

Comments
 (0)