Skip to content

Commit 40556b9

Browse files
committed
feat: Add 'object-safety' ID to init_id_map() in rustdoc
1 parent 51e22be commit 40556b9

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/librustdoc/html/markdown.rs

+1
Original file line numberDiff line numberDiff line change
@@ -2024,6 +2024,7 @@ fn init_id_map() -> FxHashMap<Cow<'static, str>, usize> {
20242024
map.insert("required-associated-consts".into(), 1);
20252025
map.insert("required-methods".into(), 1);
20262026
map.insert("provided-methods".into(), 1);
2027+
map.insert("object-safety".into(), 1);
20272028
map.insert("implementors".into(), 1);
20282029
map.insert("synthetic-implementors".into(), 1);
20292030
map.insert("implementations-list".into(), 1);

src/librustdoc/html/render/print_item.rs

+2-1
Original file line numberDiff line numberDiff line change
@@ -965,7 +965,8 @@ fn item_trait(w: &mut Buffer, cx: &mut Context<'_>, it: &clean::Item, t: &clean:
965965
w,
966966
"object-safety",
967967
"Object Safety",
968-
&format!("<div class=\"object-safety-info\">This trait is <b>not</b> \
968+
&format!(
969+
"<div class=\"object-safety-info\">This trait is <b>not</b> \
969970
<a href=\"{base}/reference/items/traits.html#object-safety\">\
970971
object safe</a>.</div>",
971972
base = crate::clean::utils::DOC_RUST_LANG_ORG_CHANNEL

0 commit comments

Comments
 (0)