about summary refs log tree commit diff
path: root/src/test/ui/span
diff options
context:
space:
mode:
authorCamille GILLOT <gillot.camille@gmail.com>2022-02-13 16:27:59 +0100
committerCamille GILLOT <gillot.camille@gmail.com>2022-07-01 17:39:19 +0200
commit42e4eee8931479a02c11c88ddaddb3a494e136c6 (patch)
treea1b3bade4e24fbe6bbcff84376aed94bc6505257 /src/test/ui/span
parentca1e68b3229e710c3948a361ee770d846a88e6da (diff)
downloadrust-42e4eee8931479a02c11c88ddaddb3a494e136c6.tar.gz
rust-42e4eee8931479a02c11c88ddaddb3a494e136c6.zip
Shorten def_span for more items.
Diffstat (limited to 'src/test/ui/span')
-rw-r--r--src/test/ui/span/impl-wrong-item-for-trait.stderr2
-rw-r--r--src/test/ui/span/issue-39018.stderr10
-rw-r--r--src/test/ui/span/multiline-span-E0072.stderr10
-rw-r--r--src/test/ui/span/transitive-dep-span.stderr19
4 files changed, 16 insertions, 25 deletions
diff --git a/src/test/ui/span/impl-wrong-item-for-trait.stderr b/src/test/ui/span/impl-wrong-item-for-trait.stderr
index 82ef13f3362..f919092f9ee 100644
--- a/src/test/ui/span/impl-wrong-item-for-trait.stderr
+++ b/src/test/ui/span/impl-wrong-item-for-trait.stderr
@@ -38,7 +38,7 @@ error[E0046]: not all trait items implemented, missing: `MY_CONST`
   --> $DIR/impl-wrong-item-for-trait.rs:19:1
    |
 LL |     const MY_CONST: u32;
-   |     -------------------- `MY_CONST` from trait
+   |     ------------------- `MY_CONST` from trait
 ...
 LL | impl Foo for FooMethodForConst {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ missing `MY_CONST` in implementation
diff --git a/src/test/ui/span/issue-39018.stderr b/src/test/ui/span/issue-39018.stderr
index e0cfe04cf41..eea94643e0a 100644
--- a/src/test/ui/span/issue-39018.stderr
+++ b/src/test/ui/span/issue-39018.stderr
@@ -29,14 +29,8 @@ LL | enum World {
 note: the following trait must be implemented
   --> $SRC_DIR/core/src/ops/arith.rs:LL:COL
    |
-LL | / pub trait Add<Rhs = Self> {
-LL | |     /// The resulting type after applying the `+` operator.
-LL | |     #[stable(feature = "rust1", since = "1.0.0")]
-LL | |     type Output;
-...  |
-LL | |     fn add(self, rhs: Rhs) -> Self::Output;
-LL | | }
-   | |_^
+LL | pub trait Add<Rhs = Self> {
+   | ^^^^^^^^^^^^^^^^^^^^^^^^^
 
 error[E0369]: cannot add `String` to `&str`
   --> $DIR/issue-39018.rs:11:22
diff --git a/src/test/ui/span/multiline-span-E0072.stderr b/src/test/ui/span/multiline-span-E0072.stderr
index acfc60b51f3..79b13f45fd8 100644
--- a/src/test/ui/span/multiline-span-E0072.stderr
+++ b/src/test/ui/span/multiline-span-E0072.stderr
@@ -3,12 +3,10 @@ error[E0072]: recursive type `ListNode` has infinite size
    |
 LL | / struct
 LL | | ListNode
-LL | | {
-LL | |     head: u8,
-LL | |     tail: Option<ListNode>,
-   | |           ---------------- recursive without indirection
-LL | | }
-   | |_^ recursive type has infinite size
+   | |________^ recursive type has infinite size
+...
+LL |       tail: Option<ListNode>,
+   |             ---------------- recursive without indirection
    |
 help: insert some indirection (e.g., a `Box`, `Rc`, or `&`) to make `ListNode` representable
    |
diff --git a/src/test/ui/span/transitive-dep-span.stderr b/src/test/ui/span/transitive-dep-span.stderr
index 2b3dfc5c135..4dc3e572116 100644
--- a/src/test/ui/span/transitive-dep-span.stderr
+++ b/src/test/ui/span/transitive-dep-span.stderr
@@ -1,19 +1,18 @@
 error: expected one of `!` or `::`, found `error`
   --> $DIR/auxiliary/transitive_dep_three.rs:6:27
    |
-LL | /         macro_rules! parse_error {
-LL | |             () => { parse error }
-   | |                           ^^^^^ expected one of `!` or `::`
-LL | |         }
-   | |_________- in this expansion of `transitive_dep_two::parse_error!`
+LL |         macro_rules! parse_error {
+   |         ------------------------ in this expansion of `transitive_dep_two::parse_error!`
+LL |             () => { parse error }
+   |                           ^^^^^ expected one of `!` or `::`
    |
   ::: $DIR/transitive-dep-span.rs:13:1
    |
-LL |   transitive_dep_two::parse_error!();
-   |   ----------------------------------
-   |   |
-   |   in this macro invocation
-   |   in this macro invocation
+LL | transitive_dep_two::parse_error!();
+   | ----------------------------------
+   | |
+   | in this macro invocation
+   | in this macro invocation
 
 error: aborting due to previous error