void *suspend(void): detach caller state before a foreign thread waits.
void resume(void *): restore that state on the same thread, even on dispatch failure.
void onError(void *): consume setNativeError's pointer on the original thread.
Optionalnotifyvoid notify(void): after queueing on a foreign thread, while suspended; may wake the host, never run JS.
Opt-in native runtime hooks. Addresses are resolved once at construction. Keep the callback and hook libraries alive until every invocation returns; retaining a function does not prevent explicit close()/release(). Hooks use the default C ABI directly, bypassing JS argument conversion and errcheck. They must not throw or execute JavaScript and do not provide subinterpreter support.