diff options
| author | bors <bors@rust-lang.org> | 2020-01-06 09:31:27 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2020-01-06 09:31:27 +0000 |
| commit | a80e63f3fa77792e848e3b248acf4c0acda2e310 (patch) | |
| tree | 6e9574bac0128d5184af68d208b2ee8d9e98e416 /src/librustdoc/html | |
| parent | 33640f0e03af2fb31ce380d5389d5545f24ce29a (diff) | |
| parent | 34716a31db9371501fe98100a7aa1566f37c1d23 (diff) | |
| download | rust-a80e63f3fa77792e848e3b248acf4c0acda2e310.tar.gz rust-a80e63f3fa77792e848e3b248acf4c0acda2e310.zip | |
Auto merge of #67917 - Dylan-DPC:rollup-id05y91, r=Dylan-DPC
Rollup of 6 pull requests Successful merges: - #67800 (Fix ICE involving calling `Instance.ty` during const evaluation) - #67873 (change remove to have a PartialEq bound) - #67897 (Use `as_deref()` to replace `as_ref().map(...)`) - #67906 (Silence `TooGeneric` error) - #67912 (macros: typo fix) - #67915 (Use Self instead of $type) Failed merges: r? @ghost
Diffstat (limited to 'src/librustdoc/html')
| -rw-r--r-- | src/librustdoc/html/render.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/librustdoc/html/render.rs b/src/librustdoc/html/render.rs index c315cefc1b8..85661621fba 100644 --- a/src/librustdoc/html/render.rs +++ b/src/librustdoc/html/render.rs @@ -2152,7 +2152,7 @@ fn stability_tags(item: &clean::Item) -> String { } if let Some(stab) = item.stability.as_ref().filter(|s| s.level == stability::Unstable) { - if stab.feature.as_ref().map(|s| &**s) == Some("rustc_private") { + if stab.feature.as_deref() == Some("rustc_private") { tags += &tag_html("internal", "Internal"); } else { tags += &tag_html("unstable", "Experimental"); @@ -2205,7 +2205,7 @@ fn short_stability(item: &clean::Item, cx: &Context) -> Vec<String> { } if let Some(stab) = item.stability.as_ref().filter(|stab| stab.level == stability::Unstable) { - let is_rustc_private = stab.feature.as_ref().map(|s| &**s) == Some("rustc_private"); + let is_rustc_private = stab.feature.as_deref() == Some("rustc_private"); let mut message = if is_rustc_private { "<span class='emoji'>⚙️</span> This is an internal compiler API." @@ -2214,7 +2214,7 @@ fn short_stability(item: &clean::Item, cx: &Context) -> Vec<String> { } .to_owned(); - if let Some(feature) = stab.feature.as_ref() { + if let Some(feature) = stab.feature.as_deref() { let mut feature = format!("<code>{}</code>", Escape(&feature)); if let (Some(url), Some(issue)) = (&cx.shared.issue_tracker_base_url, stab.issue) { feature.push_str(&format!( |
