Skip to main content

PlaceRead

Trait PlaceRead 

Source
pub unsafe trait PlaceRead<P>
where P: Projection + ?Sized, Self: HasPlace<Target = P::Source>,
{ // Required method unsafe fn read(ptr: *const Self, p: &P) -> P::Target where P::Target: Sized; }
Expand description

Read a value from a subplace.

Required Methods§

Source

unsafe fn read(ptr: *const Self, p: &P) -> P::Target
where P::Target: Sized,

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl<P: Projection + ?Sized> PlaceRead<P> for *const P::Source

Source§

unsafe fn read(ptr: *const Self, p: &P) -> P::Target
where P::Target: Sized,

Source§

impl<P: Projection + ?Sized> PlaceRead<P> for *mut P::Source

Source§

unsafe fn read(ptr: *const Self, p: &P) -> P::Target
where P::Target: Sized,

Implementors§

Source§

impl<P: Projection + ?Sized> PlaceRead<P> for &'_ P::Source