Skip to main content

jit_v2_struct_release

Function jit_v2_struct_release 

Source
#[unsafe(no_mangle)]
pub extern "C" fn jit_v2_struct_release(ptr: *mut u8, total_size: u32)
Expand description

Decrement the refcount of a v2 typed struct. Deallocates when it reaches 0.

§Arguments

  • ptr - Pointer to the struct.
  • total_size - Total allocation size (must match the size passed to jit_v2_struct_alloc).

§Safety

ptr must be a valid v2 struct pointer (or null). total_size must match the original allocation size.