Trait enum_ptr::Aligned

source ·
pub unsafe trait Aligned {
    type Pointee;
}
Expand description

Mark that a pointer type is properly aligned and can be used in EnumPtr.

Safety

T must be aligned by align_of::<Pointee>() (low bits are always zeros).

For example, raw pointers are not guaranteed to be aligned, so implementing this trait for them is unsound.

Required Associated Types§

Implementations on Foreign Types§

Implementors§