Function opaque_pointer::object

pub unsafe fn object<'a, T>(pointer: *const T) -> Result<&'a T, PointerError>
Expand description

Reference to a object but without to own it.

§Errors

The pointer must be not null as it is an obvious invalid pointer.

§Safety

Invalid pointer could cause an undefined behavior or heap error and a crash.