Questions about noreturn functions
I have a function in C:
void no_return(){
siglongjmp(previous_saved_place, 1)
}
I call this from a function in Python from within a callback context from C:
@callback_context
def cb(some_args):
ffi.lib.no_return()
When the callback is called again CFFI interprets the subsequent call to cb
as a recursive call to cb
. It eventually hits a maximum recursive depth provided by Python.
Is there some way that I can mark a function (e.g. no_return
) as non-returning/divergent so that CFFI knows that subsequent calls are not, in fact, part of the same stack and the stack can be cleaned up?