pub unsafe extern "C" fn nix_alloc_primop(
context: *mut nix_c_context,
fun: PrimOpFun,
arity: c_int,
name: *const c_char,
args: *mut *const c_char,
doc: *const c_char,
user_data: *mut c_void,
) -> *mut PrimOpExpand description
Allocate a PrimOp @ingroup primops Call nix_gc_decref() when you’re done with the returned PrimOp.
§Arguments
context[out] - Optional, stores error informationfun[in] - callbackarity[in] - expected number of function argumentsname[in] - function nameargs[in] - array of argument names, NULL-terminateddoc[in] - optional, documentation for this primopuser_data[in] - optional, arbitrary data, passed to the callback when it’s called
§Returns
primop, or null in case of errors