TraitObjectSyntax in rustc_ast::ast - Rust (original) (raw)
Enum TraitObjectSyntax
#[repr(u8)]
pub enum TraitObjectSyntax {
Dyn = 0,
None = 1,
}Expand description
Syntax used to declare a trait object.
Variants§
Dyn = 0
None = 1
Trait Implementations§
impl Clone for TraitObjectSyntax
impl Debug for TraitObjectSyntax
impl<__D: SpanDecoder> Decodable<__D> for TraitObjectSyntax
fn decode(__decoder: &mut __D) -> Self
impl<__E: SpanEncoder> Encodable<__E> for TraitObjectSyntax
fn encode(&self, __encoder: &mut __E)
impl<__CTX> HashStable<__CTX> for TraitObjectSyntax
fn hash_stable(&self, __hcx: &mut __CTX, __hasher: &mut StableHasher)
impl<V: MutVisitor> MutVisitable for TraitObjectSyntax
type Extra = ()
fn visit_mut(&mut self, visitor: &mut V, _extra: Self::Extra) -> V::Result
impl<__V> MutWalkable<__V> for TraitObjectSyntax
fn walk_mut(&mut self, __visitor: &mut __V)
impl PartialEq for TraitObjectSyntax
fn eq(&self, other: &TraitObjectSyntax) -> bool
Tests for self and other values to be equal, and is used by ==.
fn ne(&self, other: &Rhs) -> bool
Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
impl Tag for TraitObjectSyntax
SAFETY: TraitObjectSyntax only has 3 data-less variants which means it can be represented with a u2. We use repr(u8) to guarantee the discriminants of the variants are no greater than 3.
impl<'a, V: Visitor<'a>> Visitable<'a, V> for TraitObjectSyntax
type Extra = ()
fn visit(&'a self, visitor: &mut V, _extra: Self::Extra) -> V::Result
impl<'__ast, __V> Walkable<'__ast, __V> for TraitObjectSyntax
fn walk_ref(&'__ast self, __visitor: &mut __V) -> __V::Result
impl Copy for TraitObjectSyntax
impl StructuralPartialEq for TraitObjectSyntax
Auto Trait Implementations§
impl DynSend for TraitObjectSyntax
impl DynSync for TraitObjectSyntax
impl Freeze for TraitObjectSyntax
impl RefUnwindSafe for TraitObjectSyntax
impl Send for TraitObjectSyntax
impl Sync for TraitObjectSyntax
impl Unpin for TraitObjectSyntax
impl UnwindSafe for TraitObjectSyntax
Blanket Implementations§
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 1 byte
Size for each variant:
Dyn: 0 bytesNone: 0 bytes