Skip to main content

SectionItemLocation

Trait SectionItemLocation 

Source
pub trait SectionItemLocation<T: ?Sized> {
    // Required method
    fn item_ptr(&self) -> *const T;
}
Expand description

Argument to crate::TypedSection::offset_of and related section lookup APIs.

Required Methods§

Source

fn item_ptr(&self) -> *const T

Address of the item’s storage in the link section (not the wrapper).

Dyn Compatibility§

This trait is dyn compatible.

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

Implementations on Foreign Types§

Source§

impl<T: ?Sized> SectionItemLocation<T> for &T

Implementors§