Since the pointers have already been confirmed to be non-null by the assert!() calls, there is no need to use .as_ref() and the raw pointers can be dereferenced directly. See the Null-unchecked version section of the standard library documentation for the pointer type's as_ref method.
Since the pointers have already been confirmed to be non-null by the assert!() calls, there is no need to use .as_ref() and the raw pointers can be dereferenced directly. See the Null-unchecked version section of the standard library documentation for the
pointer
type'sas_ref
method.