]> git.lizzy.rs Git - rust.git/commitdiff
use span instead of div for since version
authorAndy Russell <arussell123@gmail.com>
Fri, 3 May 2019 16:55:31 +0000 (12:55 -0400)
committerAndy Russell <arussell123@gmail.com>
Fri, 3 May 2019 16:55:31 +0000 (12:55 -0400)
src/librustdoc/html/render.rs
src/librustdoc/html/static/rustdoc.css
src/test/rustdoc/assoc-consts-version.rs

index f4af362a55702c10b01fdb3bb8156f794aef0507..472192a6464921a69b5da6e044a625d16790ce6d 100644 (file)
@@ -3410,7 +3410,7 @@ fn render_stability_since_raw<'a, T: fmt::Write>(
 ) -> fmt::Result {
     if let Some(v) = ver {
         if containing_ver != ver && v.len() > 0 {
-            write!(w, "<div class='since' title='Stable since Rust version {0}'>{0}</div>", v)?
+            write!(w, "<span class='since' title='Stable since Rust version {0}'>{0}</span>", v)?
         }
     }
     Ok(())
index 358549117a3077040dfcb4158cdea8248139c852..4204d20498d701a5f74a76ded3bdb18c50ac2809 100644 (file)
@@ -914,7 +914,7 @@ h3 > .collapse-toggle, h4 > .collapse-toggle {
        height: 12px;
 }
 
-span.since {
+.out-of-band > span.since {
        position: initial;
        font-size: 20px;
        margin-right: 5px;
index c561269cf9a856fab03feacda61a7ccb061fabb7..6060bc0a6fd5c4d62b70a3b35f691fbe1d5f8a7e 100644 (file)
@@ -1,5 +1,3 @@
-// ignore-tidy-linelength
-
 #![crate_name = "foo"]
 
 #![feature(staged_api)]
@@ -10,7 +8,8 @@
 pub struct SomeStruct;
 
 impl SomeStruct {
-    // @has 'foo/struct.SomeStruct.html' '//*[@id="associatedconstant.SOME_CONST"]//div[@class="since"]' '1.1.2'
+    // @has 'foo/struct.SomeStruct.html' \
+    //   '//*[@id="associatedconstant.SOME_CONST"]//span[@class="since"]' '1.1.2'
     #[stable(since="1.1.2", feature="rust2")]
     pub const SOME_CONST: usize = 0;
 }