Struct syntax::ast::Generics
[−]
[src]
pub struct Generics { pub params: Vec<GenericParam>, pub where_clause: WhereClause, pub span: Span, }
Represents lifetime, type and const parameters attached to a declaration of a function, enum, trait, etc.
Fields
params: Vec<GenericParam>
where_clause: WhereClause
span: Span
Methods
impl Generics
[src]
pub fn is_lt_parameterized(&self) -> bool
[src]
pub fn is_type_parameterized(&self) -> bool
[src]
pub fn is_parameterized(&self) -> bool
[src]
pub fn span_for_name(&self, name: &str) -> Option<Span>
[src]
Trait Implementations
impl Clone for Generics
[src]
fn clone(&self) -> Generics
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl PartialEq for Generics
[src]
fn eq(&self, __arg_0: &Generics) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Generics) -> bool
[src]
This method tests for !=
.
impl Eq for Generics
[src]
impl Encodable for Generics
[src]
impl Decodable for Generics
[src]
impl Hash for Generics
[src]
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
[src]
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl Debug for Generics
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more