pub fn each_top_level_item_of_crate<F, G>(intr: Rc<IdentInterner>,
                                          cdata: Cmd,
                                          get_crate_data: G,
                                          callback: F) where
    F: FnMut(DefLike, ast::Name, hir::Visibility),
    G: FnMut(ast::CrateNum) -> Rc<crate_metadata>,
{
    let root_doc = rbml::Doc::new(cdata.data());
    let misc_info_doc = reader::get_doc(root_doc, tag_misc_info);
    let crate_items_doc = reader::get_doc(misc_info_doc,
                                          tag_misc_info_crate_items);

    each_child_of_item_or_crate(intr,
                                cdata,
                                crate_items_doc,
                                get_crate_data,
                                callback)
}
/// Iterates over all the top-level crate items.
Iterates over all the top-level crate items.
Iterates over all the top - level crate items .
pub fn each_top_level_item_of_crate<F, G>(intr: Rc<IdentInterner>,
                                          cdata: Cmd,
                                          get_crate_data: G,
                                          callback: F) where
    F: FnMut(DefLike, ast::Name, hir::Visibility),
    G: FnMut(ast::CrateNum) -> Rc<crate_metadata>,
{
    let root_doc = rbml::Doc::new(cdata.data());
    let misc_info_doc = reader::get_doc(root_doc, tag_misc_info);
    let crate_items_doc = reader::get_doc(misc_info_doc,
                                          tag_misc_info_crate_items);
    each_child_of_item_or_crate(intr,
                                cdata,
                                crate_items_doc,
                                get_crate_data,
                                callback)
}
pub fn each_top_level_item_of_crate < F , G > ( intr : Rc < IdentInterner > , cdata : Cmd , get_crate_data : G , callback : F ) where F : FnMut ( DefLike , ast :: Name , hir :: Visibility ) , G : FnMut ( ast :: CrateNum ) -> Rc < crate_metadata > , { let root_doc = rbml :: Doc :: new ( cdata . data ( ) ) ; let misc_info_doc = reader :: get_doc ( root_doc , tag_misc_info ) ; let crate_items_doc = reader :: get_doc ( misc_info_doc , tag_misc_info_crate_items ) ; each_child_of_item_or_crate ( intr , cdata , crate_items_doc , get_crate_data , callback ) }
Iterates over all the top-level crate items.
Iterates over all the top - level crate items .
intr
Rc<IdentInterner>
cdata
Cmd
get_crate_data
G
callback
F
intr
Rc<IdentInterner>
cdata
Cmd
get_crate_data
G
callback
F