Skip to content

Commit 236ad64

Browse files
committed
Fix slot wrappers for __getattribute__
1 parent 50e8470 commit 236ad64

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

graalpython/com.oracle.graal.python.cext/src/typeobject.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -750,13 +750,13 @@ int type_ready_graalpy_slot_conv(PyTypeObject* cls, PyObject* dict) {
750750

751751
// NOTE: The slots may be called from managed code, i.e., we need to wrap the functions
752752
// and convert arguments that should be C primitives.
753-
ADD_SLOT_CONV("__getattr__", cls->tp_getattr, -2, JWRAPPER_GETATTR);
753+
ADD_SLOT_CONV("__getattribute__", cls->tp_getattr, -2, JWRAPPER_GETATTR);
754754
ADD_SLOT_CONV("__setattr__", cls->tp_setattr, -3, JWRAPPER_SETATTR);
755755
ADD_SLOT_CONV("__repr__", cls->tp_repr, -1, JWRAPPER_REPR);
756756
ADD_SLOT_CONV("__hash__", cls->tp_hash, -1, JWRAPPER_HASHFUNC);
757757
ADD_SLOT_CONV("__call__", cls->tp_call, METH_KEYWORDS | METH_VARARGS, JWRAPPER_CALL);
758758
ADD_SLOT_CONV("__str__", cls->tp_str, -1, JWRAPPER_STR);
759-
ADD_SLOT_CONV("__getattr__", cls->tp_getattro, -2, JWRAPPER_DIRECT);
759+
ADD_SLOT_CONV("__getattribute__", cls->tp_getattro, -2, JWRAPPER_DIRECT);
760760
ADD_SLOT_CONV("__setattr__", cls->tp_setattro, -3, JWRAPPER_SETATTRO);
761761
ADD_SLOT_CONV("__clear__", cls->tp_clear, -1, JWRAPPER_INQUIRY);
762762

0 commit comments

Comments
 (0)