#[no_mangle]
pub extern "C" fn nstd_core_ptr_new(
    obj: NSTDAny,
    size: NSTDUInt
) -> NSTDOptionalPtr
Available on crate feature nstd_core only.
Expand description

Creates a new instance of NSTDPtr.

Parameters:

  • NSTDAny obj - The object to point to.

  • NSTDUInt size - The number of bytes that obj’s type occupies.

Returns

NSTDOptionalPtr ptr - A new instance of NSTDPtr that points to obj on success, or an uninitialized “none” variant if either obj is null or size is greater than NSTDInt’s max value.