diff options
| author | Michael Goulet <michael@errs.io> | 2023-01-11 03:21:11 +0000 |
|---|---|---|
| committer | Michael Goulet <michael@errs.io> | 2023-01-11 19:46:45 +0000 |
| commit | 9a39d7e441fb5f879a25d326d6f1546b34d4c531 (patch) | |
| tree | 642f7a88688ea679644971f8e96f57e988447bfc /tests/ui/traits/inductive-overflow | |
| parent | b22c152958eade17a71d899b29a2d39bcc77aa48 (diff) | |
| download | rust-9a39d7e441fb5f879a25d326d6f1546b34d4c531.tar.gz rust-9a39d7e441fb5f879a25d326d6f1546b34d4c531.zip | |
Note predicate span on ImplDerivedObligation
Diffstat (limited to 'tests/ui/traits/inductive-overflow')
4 files changed, 12 insertions, 5 deletions
diff --git a/tests/ui/traits/inductive-overflow/lifetime.rs b/tests/ui/traits/inductive-overflow/lifetime.rs index 004e477374a..bf536d21cf9 100644 --- a/tests/ui/traits/inductive-overflow/lifetime.rs +++ b/tests/ui/traits/inductive-overflow/lifetime.rs @@ -16,6 +16,7 @@ struct C<'a>(&'a ()); struct X<T: Y>(T::P); impl<T: NotAuto> NotAuto for Box<T> {} //~ NOTE: required +//~^ NOTE unsatisfied trait bound introduced here impl<T: Y> NotAuto for X<T> where T::P: NotAuto {} impl<'a> NotAuto for C<'a> {} diff --git a/tests/ui/traits/inductive-overflow/lifetime.stderr b/tests/ui/traits/inductive-overflow/lifetime.stderr index b72d53bddbc..357e59991a3 100644 --- a/tests/ui/traits/inductive-overflow/lifetime.stderr +++ b/tests/ui/traits/inductive-overflow/lifetime.stderr @@ -1,5 +1,5 @@ error[E0275]: overflow evaluating the requirement `X<C<'_>>: NotAuto` - --> $DIR/lifetime.rs:28:5 + --> $DIR/lifetime.rs:29:5 | LL | is_send::<X<C<'static>>>(); | ^^^^^^^^^^^^^^^^^^^^^^^^ @@ -8,11 +8,13 @@ note: required for `Box<X<C<'_>>>` to implement `NotAuto` --> $DIR/lifetime.rs:18:18 | LL | impl<T: NotAuto> NotAuto for Box<T> {} - | ^^^^^^^ ^^^^^^ + | ------- ^^^^^^^ ^^^^^^ + | | + | unsatisfied trait bound introduced here = note: 3 redundant requirements hidden = note: required for `X<C<'static>>` to implement `NotAuto` note: required by a bound in `is_send` - --> $DIR/lifetime.rs:22:15 + --> $DIR/lifetime.rs:23:15 | LL | fn is_send<S: NotAuto>() {} | ^^^^^^^ required by this bound in `is_send` diff --git a/tests/ui/traits/inductive-overflow/simultaneous.stderr b/tests/ui/traits/inductive-overflow/simultaneous.stderr index 09930e60efe..e3b4ec07d23 100644 --- a/tests/ui/traits/inductive-overflow/simultaneous.stderr +++ b/tests/ui/traits/inductive-overflow/simultaneous.stderr @@ -8,7 +8,9 @@ note: required for `{integer}` to implement `Combo` --> $DIR/simultaneous.rs:11:34 | LL | impl<T: Tweedledee + Tweedledum> Combo for T {} - | ^^^^^ ^ + | ---------- ^^^^^ ^ + | | + | unsatisfied trait bound introduced here note: required by a bound in `is_ee` --> $DIR/simultaneous.rs:13:13 | diff --git a/tests/ui/traits/inductive-overflow/supertrait.stderr b/tests/ui/traits/inductive-overflow/supertrait.stderr index 4b862cf79ce..b537ecf1721 100644 --- a/tests/ui/traits/inductive-overflow/supertrait.stderr +++ b/tests/ui/traits/inductive-overflow/supertrait.stderr @@ -8,7 +8,9 @@ note: required for `NoClone` to implement `Magic` --> $DIR/supertrait.rs:5:16 | LL | impl<T: Magic> Magic for T {} - | ^^^^^ ^ + | ----- ^^^^^ ^ + | | + | unsatisfied trait bound introduced here note: required by a bound in `copy` --> $DIR/supertrait.rs:7:12 | |
