Skip to content

Commit 152d4e7

Browse files
Update HTML DOM attribute "edition" to "data-edition"
1 parent 9b62936 commit 152d4e7

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/librustdoc/html/highlight.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ crate fn render_with_highlighting(
3030
"<div class='information'><div class='tooltip {}'{}>ⓘ</div></div>",
3131
class,
3232
if let Some(edition_info) = edition_info {
33-
format!(" edition=\"{}\"", edition_info)
33+
format!(" data-edition=\"{}\"", edition_info)
3434
} else {
3535
String::new()
3636
},

src/librustdoc/html/static/rustdoc.css

+1-1
Original file line numberDiff line numberDiff line change
@@ -1098,7 +1098,7 @@ h3 > .collapse-toggle, h4 > .collapse-toggle {
10981098
content: "This example panics";
10991099
}
11001100
.tooltip.edition::after {
1101-
content: "This code runs with edition " attr(edition);
1101+
content: "This code runs with edition " attr(data-edition);
11021102
}
11031103

11041104
.tooltip::before {

src/test/rustdoc/codeblock-title.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
// @has foo/fn.bar.html '//*[@class="tooltip compile_fail"]' "ⓘ"
44
// @has foo/fn.bar.html '//*[@class="tooltip ignore"]' "ⓘ"
55
// @has foo/fn.bar.html '//*[@class="tooltip should_panic"]' "ⓘ"
6-
// @has foo/fn.bar.html '//*[@edition="2018"]' "ⓘ"
6+
// @has foo/fn.bar.html '//*[@data-edition="2018"]' "ⓘ"
77

88
/// foo
99
///

0 commit comments

Comments
 (0)