Thin

Trait Alias Thin 

Source
trait Thin = Pointee<Metadata = ()>;
πŸ”¬This is a nightly-only experimental API. (ptr_metadata #81513)
Expand description

Pointers to types implementing this trait alias are β€œthin”.

This includes statically-Sized types and extern types.

Β§Example

#![feature(ptr_metadata)]

fn this_never_panics<T: std::ptr::Thin>() {
    assert_eq!(size_of::<&T>(), size_of::<usize>())
}