@@ -616,6 +616,7 @@ impl SerializedSearchIndex {
616616 parent,
617617 trait_parent,
618618 deprecated,
619+ unstable,
619620 associated_item_disambiguator,
620621 } | EntryData {
621622 krate : * map. get ( krate) . unwrap ( ) ,
@@ -626,6 +627,7 @@ impl SerializedSearchIndex {
626627 parent : parent. and_then ( |path_id| map. get ( & path_id) . copied ( ) ) ,
627628 trait_parent : trait_parent. and_then ( |path_id| map. get ( & path_id) . copied ( ) ) ,
628629 deprecated : * deprecated,
630+ unstable : * unstable,
629631 associated_item_disambiguator : associated_item_disambiguator. clone ( ) ,
630632 } ,
631633 ) ,
@@ -896,6 +898,7 @@ struct EntryData {
896898 parent : Option < usize > ,
897899 trait_parent : Option < usize > ,
898900 deprecated : bool ,
901+ unstable : bool ,
899902 associated_item_disambiguator : Option < String > ,
900903}
901904
@@ -912,6 +915,7 @@ impl Serialize for EntryData {
912915 seq. serialize_element ( & self . parent . map ( |id| id + 1 ) . unwrap_or ( 0 ) ) ?;
913916 seq. serialize_element ( & self . trait_parent . map ( |id| id + 1 ) . unwrap_or ( 0 ) ) ?;
914917 seq. serialize_element ( & if self . deprecated { 1 } else { 0 } ) ?;
918+ seq. serialize_element ( & if self . unstable { 1 } else { 0 } ) ?;
915919 if let Some ( disambig) = & self . associated_item_disambiguator {
916920 seq. serialize_element ( & disambig) ?;
917921 }
@@ -946,6 +950,7 @@ impl<'de> Deserialize<'de> for EntryData {
946950 v. next_element ( ) ?. ok_or_else ( || A :: Error :: missing_field ( "trait_parent" ) ) ?;
947951
948952 let deprecated: u32 = v. next_element ( ) ?. unwrap_or ( 0 ) ;
953+ let unstable: u32 = v. next_element ( ) ?. unwrap_or ( 0 ) ;
949954 let associated_item_disambiguator: Option < String > = v. next_element ( ) ?;
950955 Ok ( EntryData {
951956 krate,
@@ -956,6 +961,7 @@ impl<'de> Deserialize<'de> for EntryData {
956961 parent : Option :: < i32 > :: from ( parent) . map ( |path| path as usize ) ,
957962 trait_parent : Option :: < i32 > :: from ( trait_parent) . map ( |path| path as usize ) ,
958963 deprecated : deprecated != 0 ,
964+ unstable : unstable != 0 ,
959965 associated_item_disambiguator,
960966 } )
961967 }
@@ -1283,6 +1289,7 @@ pub(crate) fn build_index(
12831289 ) ,
12841290 aliases : item. attrs . get_doc_aliases ( ) ,
12851291 is_deprecated : item. is_deprecated ( tcx) ,
1292+ is_unstable : item. is_unstable ( ) ,
12861293 } ) ;
12871294 }
12881295 }
@@ -1382,6 +1389,7 @@ pub(crate) fn build_index(
13821389 parent : None ,
13831390 trait_parent : None ,
13841391 deprecated : false ,
1392+ unstable : false ,
13851393 associated_item_disambiguator : None ,
13861394 } ) ,
13871395 crate_doc,
@@ -1520,6 +1528,7 @@ pub(crate) fn build_index(
15201528 module_path,
15211529 exact_module_path,
15221530 deprecated : item. is_deprecated ,
1531+ unstable : item. is_unstable ,
15231532 associated_item_disambiguator : if let Some ( impl_id) = item. impl_id
15241533 && let Some ( parent_idx) = item. parent_idx
15251534 && associated_item_duplicates
0 commit comments