Skip to content

Commit 0997af9

Browse files
committed
py: Don't wrap necessary function calls in assert.
1 parent 0aa4379 commit 0997af9

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

py/objgenerator.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,9 @@ STATIC mp_obj_t gen_wrap_call(mp_obj_t self_in, uint n_args, uint n_kw, const mp
3030

3131
const mp_obj_t *args1, *args2;
3232
uint len1, len2;
33-
assert(mp_obj_fun_prepare_simple_args(self_fun, n_args, n_kw, args, &len1, &args1, &len2, &args2));
33+
if (!mp_obj_fun_prepare_simple_args(self_fun, n_args, n_kw, args, &len1, &args1, &len2, &args2)) {
34+
assert(0);
35+
}
3436

3537
return mp_obj_new_gen_instance(bc_code, len1, args1, len2, args2);
3638
}

0 commit comments

Comments
 (0)