pub type TlsDataImage = LocalStorageDataImage<Tls>;

Aliased Type§

struct TlsDataImage { /* private fields */ }

Implementations§

source§

impl<T> LocalStorageDataImage<T>where T: LocalStorage,

source

pub const fn new() -> Self

Creates an empty data image.

source

pub fn inherit(&mut self, other: &Self)

Inherits the data from another data image.

Panics

Panics if the other image has a longer length, or (on x86_64) if the other image has a differently sized static area.

source§

impl LocalStorageDataImage<Tls>

source

pub unsafe fn set_as_current_tls(&self)

Sets the data image.

Safety

The data image must not be dropped until another data image replaces it, or until thread-local storage will never be accessed from the current thread again.

Trait Implementations§

source§

impl<T> Debug for LocalStorageDataImage<T>where T: LocalStorage + Debug,

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more