Struct syntax::ast::MetaItem  [−][src]
pub struct MetaItem {
    pub ident: Path,
    pub node: MetaItemKind,
    pub span: Span,
}A spanned compile-time attribute item.
E.g. #[test], #[derive(..)], #[rustfmt::skip] or #[feature = "foo"]
Fields
ident: Path
                           
                           
                           
                           node: MetaItemKind
                           
                           
                           
                           span: Span
                           
                    Methods
impl MetaItem[src] 
impl MetaItempub fn name(&self) -> Name[src] 
pub fn name(&self) -> Namepub fn value_str(&self) -> Option<Symbol>[src] 
pub fn value_str(&self) -> Option<Symbol>pub fn meta_item_list(&self) -> Option<&[NestedMetaItem]>[src] 
pub fn meta_item_list(&self) -> Option<&[NestedMetaItem]>pub fn is_word(&self) -> bool[src] 
pub fn is_word(&self) -> boolpub fn span(&self) -> Span[src] 
pub fn span(&self) -> Spanpub fn check_name(&self, name: &str) -> bool[src] 
pub fn check_name(&self, name: &str) -> boolpub fn is_value_str(&self) -> bool[src] 
pub fn is_value_str(&self) -> boolpub fn is_meta_item_list(&self) -> bool[src] 
pub fn is_meta_item_list(&self) -> boolpub fn is_scoped(&self) -> Option<Ident>[src] 
pub fn is_scoped(&self) -> Option<Ident>Trait Implementations
impl Clone for MetaItem[src] 
impl Clone for MetaItemfn clone(&self) -> MetaItem[src] 
fn clone(&self) -> MetaItemReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src] 
fn clone_from(&mut self, source: &Self)1.0.0
[src]Performs copy-assignment from source. Read more
impl PartialEq for MetaItem[src] 
impl PartialEq for MetaItemfn eq(&self, other: &MetaItem) -> bool[src] 
fn eq(&self, other: &MetaItem) -> boolThis method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, other: &MetaItem) -> bool[src] 
fn ne(&self, other: &MetaItem) -> boolThis method tests for !=.
impl Eq for MetaItem[src] 
impl Eq for MetaItemimpl Encodable for MetaItem[src] 
impl Encodable for MetaItemimpl Decodable for MetaItem[src] 
impl Decodable for MetaItemimpl Hash for MetaItem[src] 
impl Hash for MetaItemfn hash<__H: Hasher>(&self, state: &mut __H)[src] 
fn hash<__H: Hasher>(&self, state: &mut __H)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] 
fn hash_slice<H>(data: &[Self], state: &mut H) where
    H: Hasher, 1.3.0
[src]Feeds a slice of this type into the given [Hasher]. Read more
impl Debug for MetaItem[src] 
impl Debug for MetaItemfn fmt(&self, f: &mut Formatter) -> Result[src] 
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl ToTokens for MetaItem[src] 
impl ToTokens for MetaItem