rustix

Module utils

Source
Expand description

Miscellaneous minor utilities.

Macros§

  • Create a union value containing a default value in one of its arms.

Functions§

  • as_mut_ptr 🔒
    Convert a &mut T into a *mut T without using an as.
  • as_ptr 🔒
    Convert a &T into a *const T without using an as.
  • Convert a *mut c_void to a *mut T, checking that it is not null, misaligned, or pointing to a region of memory that wraps around the address space.
  • Convert an Option<&mut T> into a possibly-null *mut T.
  • Convert an Option<&T> into a possibly-null *const T.