[][src]Struct rustc_ap_rustc_data_structures::tagged_ptr::CopyTaggedPtr

pub struct CopyTaggedPtr<P, T, const COMPARE_PACKED: bool> where
    P: Pointer,
    T: Tag
{ /* fields omitted */ }

A Copy TaggedPtr.

You should use this instead of the TaggedPtr type in all cases where P: Copy.

If COMPARE_PACKED is true, then the pointers will be compared and hashed without unpacking. Otherwise we don't implement PartialEq/Eq/Hash; if you want that, wrap the TaggedPtr.

Implementations

impl<P, T, const COMPARE_PACKED: bool> CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Pointer,
    T: Tag
[src]

pub fn new(pointer: P, tag: T) -> Self[src]

pub fn pointer(self) -> P where
    P: Copy
[src]

pub fn pointer_ref(&self) -> &P::Target[src]

pub fn pointer_mut(&mut self) -> &mut P::Target where
    P: DerefMut
[src]

pub fn tag(&self) -> T[src]

pub fn set_tag(&mut self, tag: T)[src]

Trait Implementations

impl<P, T, const COMPARE_PACKED: bool> Clone for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Pointer,
    T: Tag,
    P: Copy
[src]

impl<P, T, const COMPARE_PACKED: bool> Copy for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Pointer,
    T: Tag,
    P: Copy
[src]

impl<P, T, const COMPARE_PACKED: bool> Debug for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Pointer,
    P::Target: Debug,
    T: Tag + Debug
[src]

impl<P, T, const COMPARE_PACKED: bool> Deref for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Pointer,
    T: Tag
[src]

type Target = P::Target

The resulting type after dereferencing.

impl<P, T, const COMPARE_PACKED: bool> DerefMut for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Pointer + DerefMut,
    T: Tag
[src]

impl<P, T> Eq for CopyTaggedPtr<P, T, true> where
    P: Pointer,
    T: Tag
[src]

impl<P, T> Hash for CopyTaggedPtr<P, T, true> where
    P: Pointer,
    T: Tag
[src]

impl<P, T, HCX, const COMPARE_PACKED: bool> HashStable<HCX> for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Pointer + HashStable<HCX>,
    T: Tag + HashStable<HCX>, 
[src]

impl<P, T> PartialEq<CopyTaggedPtr<P, T, true>> for CopyTaggedPtr<P, T, true> where
    P: Pointer,
    T: Tag
[src]

Auto Trait Implementations

impl<P, T, const COMPARE_PACKED: bool> RefUnwindSafe for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: RefUnwindSafe,
    T: RefUnwindSafe

impl<P, T, const COMPARE_PACKED: bool> Send for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Send,
    T: Send

impl<P, T, const COMPARE_PACKED: bool> Sync for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Sync,
    T: Sync

impl<P, T, const COMPARE_PACKED: bool> Unpin for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: Unpin,
    T: Unpin

impl<P, T, const COMPARE_PACKED: bool> UnwindSafe for CopyTaggedPtr<P, T, COMPARE_PACKED> where
    P: UnwindSafe,
    T: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<'a, T> Captures<'a> for T where
    T: ?Sized
[src]

impl<Q, K> Equivalent<K> for Q where
    K: Borrow<Q> + ?Sized,
    Q: Eq + ?Sized
[src]

impl<T> Erased for T[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,