Make an error message more understandable and consistent with other error messages.

This commit is contained in:
Raymond Hettinger 2011-11-20 10:38:53 -08:00
parent b19284f6eb
commit 7d1483cbad

View file

@ -156,7 +156,7 @@ PyObject_GetItem(PyObject *o, PyObject *key)
"be integer, not '%.200s'", key); "be integer, not '%.200s'", key);
} }
return type_error("'%.200s' object is not subscriptable", o); return type_error("'%.200s' object has no attribute '__getitem__'", o);
} }
int int