Function is_accessible_struct

Source
pub fn is_accessible_struct<T>(target: *const T) -> bool
Expand description

Is this an accessible struct?

Returns false if

  • The address pointed to by T is null
  • When the address pointed to by T is not located at a memory address that is a multiple of T (unaligned)
  • There is no permission to access an address of size T.