@@ -574,7 +574,8 @@ fn build_index(krate: &clean::Crate, cache: &mut Cache) -> String {
574574 // has since been learned.
575575 for & ( did, ref item) in orphan_impl_items {
576576 if let Some ( & ( ref fqp, _) ) = paths. get ( & did) {
577- if item. name . is_none ( ) { // this is most likely from a typedef
577+ if item. name . is_none ( ) {
578+ // this is most likely from a typedef
578579 continue ;
579580 }
580581 search_index. push ( IndexItem {
@@ -596,22 +597,20 @@ fn build_index(krate: &clean::Crate, cache: &mut Cache) -> String {
596597
597598 for item in search_index {
598599 item. parent_idx = match item. parent {
599- Some ( nodeid) => {
600- Some ( if nodeid_to_pathid. contains_key ( & nodeid) {
601- * nodeid_to_pathid. get ( & nodeid) . expect ( "no pathid" )
602- } else {
603- let pathid = lastpathid;
604- nodeid_to_pathid. insert ( nodeid, pathid) ;
605- lastpathid += 1 ;
600+ Some ( nodeid) => Some ( if nodeid_to_pathid. contains_key ( & nodeid) {
601+ * nodeid_to_pathid. get ( & nodeid) . expect ( "no pathid" )
602+ } else {
603+ let pathid = lastpathid;
604+ nodeid_to_pathid. insert ( nodeid, pathid) ;
605+ lastpathid += 1 ;
606606
607- if let Some ( & ( ref fqp, short) ) = paths. get ( & nodeid) {
608- crate_paths. push ( ( short, fqp. last ( ) . expect ( "no fqp" ) . clone ( ) ) ) ;
609- } else {
610- continue
611- }
612- pathid
613- } )
614- }
607+ if let Some ( & ( ref fqp, short) ) = paths. get ( & nodeid) {
608+ crate_paths. push ( ( short, fqp. last ( ) . expect ( "no fqp" ) . clone ( ) ) ) ;
609+ } else {
610+ continue ;
611+ }
612+ pathid
613+ } ) ,
615614 None => None ,
616615 } ;
617616
0 commit comments