Function std::ptr::swap_ptr

pub unsafe fn swap_ptr<T>(x: *mut T, y: *mut T)

Swap the values at two mutable locations of the same type, without deinitialising or copying either one.