Enum amplify_syn::TypeClass
source · pub enum TypeClass {
Show 15 variants
Array,
BareFn,
Group,
ImplTrait,
Infer,
Macro,
Never,
Paren,
Path,
Ptr,
Reference,
Slice,
TraitObject,
Tuple,
Any,
}
Expand description
Constrains for the possible types that a Rust value could have.
Variants§
Array
A fixed size array type: [T; n]
.
BareFn
A bare function type: fn(usize) -> bool
.
Group
A type contained within invisible delimiters.
ImplTrait
An impl Bound1 + Bound2 + Bound3
type where Bound
is a trait or
a lifetime.
Infer
Indication that a type should be inferred by the compiler: _
.
Macro
A macro in the type position.
Never
The never type: !
.
Paren
A parenthesized type equivalent to the inner type.
Path
A path like std::slice::Iter
, optionally qualified with a
self-type as in <Vec<T> as SomeTrait>::Associated
.
Ptr
A raw pointer type: *const T
or *mut T
.
Reference
A reference type: &'a T
or &'a mut T
.
Slice
A dynamically sized slice type: [T]
.
TraitObject
A trait object type Bound1 + Bound2 + Bound3
where Bound
is a
trait or a lifetime.
Tuple
A tuple type: (A, B, C, String)
.
Any
Tokens in type position not interpreted by Syn.
Implementations§
Trait Implementations§
source§impl From<TypeClass> for ValueClass
impl From<TypeClass> for ValueClass
source§impl Ord for TypeClass
impl Ord for TypeClass
source§impl PartialEq<TypeClass> for TypeClass
impl PartialEq<TypeClass> for TypeClass
source§impl PartialOrd<TypeClass> for TypeClass
impl PartialOrd<TypeClass> for TypeClass
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read more