mirror of https://github.com/python/cpython.git
attribute-less object is AttributeError, not TypeError
This commit is contained in:
parent
5e56997969
commit
016564ab51
|
@ -254,7 +254,7 @@ getattr(v, name)
|
||||||
char *name;
|
char *name;
|
||||||
{
|
{
|
||||||
if (v->ob_type->tp_getattr == NULL) {
|
if (v->ob_type->tp_getattr == NULL) {
|
||||||
err_setstr(TypeError, "attribute-less object");
|
err_setstr(AttributeError, "attribute-less object");
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
Loading…
Reference in New Issue