aboutsummaryrefslogtreecommitdiff
path: root/py/objtype.c
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2018-10-18 12:15:16 +1100
committerDamien George <damien.p.george@gmail.com>2018-10-18 12:15:16 +1100
commit7eb29c200077096a4c6afc2679b35d70068de89d (patch)
treee7aa3ace0200cec6d235a92d87ae4535b87e4042 /py/objtype.c
parent4904663748a480608797fa5e22285f601bbecfff (diff)
py/objtype: Remove comment about catching exc from user __getattr__.
Any exception raised in a user __getattr__ should be propagated out. A test is added to verify these semantics.
Diffstat (limited to 'py/objtype.c')
-rw-r--r--py/objtype.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/py/objtype.c b/py/objtype.c
index 549919692..0881ae33f 100644
--- a/py/objtype.c
+++ b/py/objtype.c
@@ -654,7 +654,6 @@ STATIC void mp_obj_instance_load_attr(mp_obj_t self_in, qstr attr, mp_obj_t *des
mp_load_method_maybe(self_in, MP_QSTR___getattr__, dest2);
if (dest2[0] != MP_OBJ_NULL) {
// __getattr__ exists, call it and return its result
- // XXX if this fails to load the requested attr, should we catch the attribute error and return silently?
dest2[2] = MP_OBJ_NEW_QSTR(attr);
dest[0] = mp_call_method_n_kw(1, 0, dest2);
return;