about summary refs log tree commit diff
path: root/src/test/rustdoc-ui
diff options
context:
space:
mode:
authorEsteban Küber <esteban@kuber.com.ar>2018-06-06 00:30:25 -0700
committerEsteban Küber <esteban@kuber.com.ar>2018-06-06 08:49:42 -0700
commit507dfd2148f68bc3bd6349d5e666b12e360a9d15 (patch)
treeb15e743eb1f1a57b01b47163bc82f92647ae3ccd /src/test/rustdoc-ui
parent41affd03eb169830773cd1b11efda562ab81fad0 (diff)
downloadrust-507dfd2148f68bc3bd6349d5e666b12e360a9d15.tar.gz
rust-507dfd2148f68bc3bd6349d5e666b12e360a9d15.zip
Use spans pointing at the inside of a rustdoc attribute
Diffstat (limited to 'src/test/rustdoc-ui')
-rw-r--r--src/test/rustdoc-ui/intra-links-warning.rs8
-rw-r--r--src/test/rustdoc-ui/intra-links-warning.stderr63
2 files changed, 38 insertions, 33 deletions
diff --git a/src/test/rustdoc-ui/intra-links-warning.rs b/src/test/rustdoc-ui/intra-links-warning.rs
index 830aaabf9d2..0d886bf0972 100644
--- a/src/test/rustdoc-ui/intra-links-warning.rs
+++ b/src/test/rustdoc-ui/intra-links-warning.rs
@@ -10,10 +10,12 @@
 
 // compile-pass
 
-//! Test with [Foo::baz], [Bar::foo], ...
-//!
-//! and [Uniooon::X].
+       //! Test with [Foo::baz], [Bar::foo], ...
+       //! , [Uniooon::X] and [Qux::Z].
+       //! .
+       //! , [Uniooon::X] and [Qux::Z].
 
+       /// [Qux:Y]
 pub struct Foo {
     pub bar: usize,
 }
diff --git a/src/test/rustdoc-ui/intra-links-warning.stderr b/src/test/rustdoc-ui/intra-links-warning.stderr
index 1e8e9f04c26..a5a5598ed8f 100644
--- a/src/test/rustdoc-ui/intra-links-warning.stderr
+++ b/src/test/rustdoc-ui/intra-links-warning.stderr
@@ -1,39 +1,42 @@
-warning: [Foo::baz] cannot be resolved, ignoring it...
-  --> $DIR/intra-links-warning.rs:13:1
+warning: `[Foo::baz]` cannot be resolved, ignoring it...
+  --> $DIR/intra-links-warning.rs:13:23
    |
-13 | / //! Test with [Foo::baz], [Bar::foo], ...
-14 | | //!
-15 | | //! and [Uniooon::X].
-   | |_____________________^
+13 |        //! Test with [Foo::baz], [Bar::foo], ...
+   |                       ^^^^^^^^ cannot be resolved, ignoring
+
+warning: `[Bar::foo]` cannot be resolved, ignoring it...
+  --> $DIR/intra-links-warning.rs:13:35
    |
-   = note: the link appears in this line:
-           
-            Test with [Foo::baz], [Bar::foo], ...
-                       ^^^^^^^^
+13 |        //! Test with [Foo::baz], [Bar::foo], ...
+   |                                   ^^^^^^^^ cannot be resolved, ignoring
 
-warning: [Bar::foo] cannot be resolved, ignoring it...
-  --> $DIR/intra-links-warning.rs:13:1
+warning: `[Uniooon::X]` cannot be resolved, ignoring it...
+  --> $DIR/intra-links-warning.rs:14:15
    |
-13 | / //! Test with [Foo::baz], [Bar::foo], ...
-14 | | //!
-15 | | //! and [Uniooon::X].
-   | |_____________________^
+14 |        //! , [Uniooon::X] and [Qux::Z].
+   |               ^^^^^^^^^^ cannot be resolved, ignoring
+
+warning: `[Qux::Z]` cannot be resolved, ignoring it...
+  --> $DIR/intra-links-warning.rs:14:32
    |
-   = note: the link appears in this line:
-           
-            Test with [Foo::baz], [Bar::foo], ...
-                                   ^^^^^^^^
+14 |        //! , [Uniooon::X] and [Qux::Z].
+   |                                ^^^^^^ cannot be resolved, ignoring
 
-warning: [Uniooon::X] cannot be resolved, ignoring it...
-  --> $DIR/intra-links-warning.rs:13:1
+warning: `[Uniooon::X]` cannot be resolved, ignoring it...
+  --> $DIR/intra-links-warning.rs:16:15
    |
-13 | / //! Test with [Foo::baz], [Bar::foo], ...
-14 | | //!
-15 | | //! and [Uniooon::X].
-   | |_____________________^
+16 |        //! , [Uniooon::X] and [Qux::Z].
+   |               ^^^^^^^^^^ cannot be resolved, ignoring
+
+warning: `[Qux::Z]` cannot be resolved, ignoring it...
+  --> $DIR/intra-links-warning.rs:16:32
+   |
+16 |        //! , [Uniooon::X] and [Qux::Z].
+   |                                ^^^^^^ cannot be resolved, ignoring
+
+warning: `[Qux:Y]` cannot be resolved, ignoring it...
+  --> $DIR/intra-links-warning.rs:18:13
    |
-   = note: the link appears in this line:
-           
-            and [Uniooon::X].
-                 ^^^^^^^^^^
+18 |        /// [Qux:Y]
+   |             ^^^^^ cannot be resolved, ignoring