@@ -2126,7 +2126,7 @@ fn stability_tags(item: &clean::Item) -> String {
2126
2126
if item
2127
2127
. stability
2128
2128
. as_ref ( )
2129
- . map ( |s| s. level == stability:: Unstable && s. feature . as_deref ( ) != Some ( "rustc_private" ) )
2129
+ . map ( |s| s. level == stability:: Unstable && s. feature != "rustc_private" )
2130
2130
== Some ( true )
2131
2131
{
2132
2132
tags += & tag_html ( "unstable" , "Experimental" ) ;
@@ -2177,25 +2177,25 @@ fn short_stability(item: &clean::Item, cx: &Context) -> Vec<String> {
2177
2177
2178
2178
// Render unstable items. But don't render "rustc_private" crates (internal compiler crates).
2179
2179
// Those crates are permanently unstable so it makes no sense to render "unstable" everywhere.
2180
- if let Some ( stab) = item. stability . as_ref ( ) . filter ( |stab| {
2181
- stab. level == stability:: Unstable && stab. feature . as_deref ( ) != Some ( "rustc_private" )
2182
- } ) {
2180
+ if let Some ( stab) = item
2181
+ . stability
2182
+ . as_ref ( )
2183
+ . filter ( |stab| stab. level == stability:: Unstable && stab. feature != "rustc_private" )
2184
+ {
2183
2185
let mut message =
2184
2186
"<span class='emoji'>🔬</span> This is a nightly-only experimental API." . to_owned ( ) ;
2185
2187
2186
- if let Some ( feature) = stab. feature . as_deref ( ) {
2187
- let mut feature = format ! ( "<code>{}</code>" , Escape ( & feature) ) ;
2188
- if let ( Some ( url) , Some ( issue) ) = ( & cx. shared . issue_tracker_base_url , stab. issue ) {
2189
- feature. push_str ( & format ! (
2190
- " <a href=\" {url}{issue}\" >#{issue}</a>" ,
2191
- url = url,
2192
- issue = issue
2193
- ) ) ;
2194
- }
2195
-
2196
- message. push_str ( & format ! ( " ({})" , feature) ) ;
2188
+ let mut feature = format ! ( "<code>{}</code>" , Escape ( & stab. feature) ) ;
2189
+ if let ( Some ( url) , Some ( issue) ) = ( & cx. shared . issue_tracker_base_url , stab. issue ) {
2190
+ feature. push_str ( & format ! (
2191
+ " <a href=\" {url}{issue}\" >#{issue}</a>" ,
2192
+ url = url,
2193
+ issue = issue
2194
+ ) ) ;
2197
2195
}
2198
2196
2197
+ message. push_str ( & format ! ( " ({})" , feature) ) ;
2198
+
2199
2199
if let Some ( unstable_reason) = & stab. unstable_reason {
2200
2200
let mut ids = cx. id_map . borrow_mut ( ) ;
2201
2201
message = format ! (
0 commit comments