[][src]Trait rustc_ap_rustc_data_structures::tagged_ptr::Tag

pub unsafe trait Tag: Copy {
    pub const BITS: usize;

    pub fn into_usize(self) -> usize;
pub unsafe fn from_usize(tag: usize) -> Self; }

This describes tags that the TaggedPtr struct can hold.

Safety

The BITS constant must be correct.

No more than BITS least significant bits may be set in the returned usize.

Associated Constants

pub const BITS: usize[src]

Loading content...

Required methods

pub fn into_usize(self) -> usize[src]

pub unsafe fn from_usize(tag: usize) -> Self[src]

Safety

The passed tag must be returned from into_usize.

Loading content...

Implementors

Loading content...