Skip to main content

sidecar_r_check

Function sidecar_r_check 

Source
#[doc(hidden)]
pub unsafe fn sidecar_r_check<T: TypedExternal>(x: SEXP, require_live: bool)
Expand description

Checks that x carries an external pointer to a T (sidecar_receiver), live or (without require_live) read back by readRDS(), before a setter validates its value.

§Panics

When x carries no external pointer to a T (checked_prot), or with the miniextendr_borrow_conflict R error while a running call holds the value.

§Safety

Must be called from R’s main thread with a valid x.