Skip to main content

JS_IsJobPending

Function JS_IsJobPending 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn JS_IsJobPending(rt: *mut JsRuntime) -> Bool
Expand description

JS_IsJobPending: whether a job is waiting for JS_ExecutePendingJob.

An evaluation drains its own jobs, so this only answers non-zero for what a host queued with JS_EnqueueJob (or a promise a C callback settled) — which is exactly what a host asks the question for.

§Safety

rt must be a live runtime.