8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 30268c9 commit fe2bc92Copy full SHA for fe2bc92
py/runtime.c
@@ -1372,8 +1372,10 @@ mp_obj_t mp_make_raise_obj(mp_obj_t o) {
1372
// create and return a new exception instance by calling o
1373
// TODO could have an option to disable traceback, then builtin exceptions (eg TypeError)
1374
// could have const instances in ROM which we return here instead
1375
- return mp_call_function_n_kw(o, 0, 0 654C , NULL);
1376
- } else if (mp_obj_is_exception_instance(o)) {
+ o = mp_call_function_n_kw(o, 0, 0, NULL);
+ }
1377
+
1378
+ if (mp_obj_is_exception_instance(o)) {
1379
// o is an instance of an exception, so use it as the exception
1380
return o;
1381
} else {
0 commit comments