Trait syn_ext::ext::MetaIteratorExt[][src]

pub trait MetaIteratorExt<'a, M> where
    M: 'a + Borrow<Meta>, 
{ fn to_multi_map<K, KF>(
        self,
        path_to_key: KF
    ) -> Result<Map<K, Vec<(usize, M)>>>
    where
        K: Hash + Eq,
        KF: Fn(&Path) -> Result<Option<K>>
;
fn to_unique_map<K, KF>(self, path_to_key: KF) -> Result<Map<K, (usize, M)>>
    where
        K: Hash + Eq,
        KF: Fn(&Path) -> Result<Option<K>>
; }
Expand description

Constructs and returns map from syn::Meta iterator

Required methods

Constructs and returns a multi-value map from syn::Meta iterator

Constructs and returns a unique-value map from syn::Meta iterator. Err if duplicates.

Implementors