pub unsafe fn vmaxget() -> *mut c_voidExpand description
Get the current R memory stack watermark.
Use with vmaxset() to restore memory stack state.
Memory allocated with R_alloc() between vmaxget() and vmaxset()
will be freed when vmaxset() is called.
§Example
ⓘ
unsafe {
let watermark = vmaxget();
let buf = R_alloc(100, 1);
// ... use buf ...
vmaxset(watermark); // frees buf
}Checked wrapper for vmaxget. Calls vmaxget_unchecked inside with_r_thread, which panics off R’s main thread.
Generated from source location line 2105, column 12.
Generated from source file miniextendr-api/src/sys.rs.