#[unsafe(no_mangle)]pub unsafe extern "C" fn cove_debug(
source: *const u8,
len: usize,
fuel: u32,
deadline_ms: u32,
moments: u32,
) -> *mut u8Expand description
Checks, lowers and runs source under a recording debugger, and answers
what cove_run answers plus the recording. See crate::debug_json.
fuel and deadline_ms are cove_run’s, meaning the same things. A
debugged run is slower than a run — the machine asks the recorder before
every instruction — so a program that finished inside the default
deadline may not finish inside it here. That is reported as a deadline
outcome beside the recording of everything up to it, which is the honest
answer and not a silent one.
moments is how many moments to keep, with zero meaning
crate::record::MOMENTS and anything larger than
crate::record::MOST_MOMENTS clamped to it. It is a u32 for
cove_run’s reason: a u64 parameter reaches JavaScript as a BigInt.
§Safety
As cove_compile.