diff options
| author | Esteban Küber <esteban@kuber.com.ar> | 2020-02-21 13:39:47 -0800 |
|---|---|---|
| committer | Esteban Küber <esteban@kuber.com.ar> | 2020-02-28 11:37:59 -0800 |
| commit | 7c29441ef2efcd47512402d5558b41a235648841 (patch) | |
| tree | b11dfe0216b7476ac9e9975f8b18bcdc7a161ff2 /src/test | |
| parent | 01286408c1d4ac9d862801ac102ce4de44fc095b (diff) | |
| download | rust-7c29441ef2efcd47512402d5558b41a235648841.tar.gz rust-7c29441ef2efcd47512402d5558b41a235648841.zip | |
Review comments: split requirement text to multiple lines for readability
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/ui/derives/derive-assoc-type-not-impl.stderr | 3 | ||||
| -rw-r--r-- | src/test/ui/issues/issue-21596.stderr | 3 | ||||
| -rw-r--r-- | src/test/ui/issues/issue-31173.stderr | 6 | ||||
| -rw-r--r-- | src/test/ui/methods/method-call-err-msg.stderr | 3 | ||||
| -rw-r--r-- | src/test/ui/mismatched_types/issue-36053-2.stderr | 9 | ||||
| -rw-r--r-- | src/test/ui/suggestions/missing-trait-bounds-for-method-call.stderr | 9 | ||||
| -rw-r--r-- | src/test/ui/suggestions/mut-borrow-needed-by-trait.stderr | 3 | ||||
| -rw-r--r-- | src/test/ui/union/union-derive-clone.stderr | 3 | ||||
| -rw-r--r-- | src/test/ui/unique-object-noncopyable.stderr | 6 | ||||
| -rw-r--r-- | src/test/ui/unique-pinned-nocopy.stderr | 3 |
10 files changed, 32 insertions, 16 deletions
diff --git a/src/test/ui/derives/derive-assoc-type-not-impl.stderr b/src/test/ui/derives/derive-assoc-type-not-impl.stderr index e837c7721af..c4c85773fbc 100644 --- a/src/test/ui/derives/derive-assoc-type-not-impl.stderr +++ b/src/test/ui/derives/derive-assoc-type-not-impl.stderr @@ -14,7 +14,8 @@ LL | Bar::<NotClone> { x: 1 }.clone(); | ^^^^^ method not found in `Bar<NotClone>` | = note: the method `clone` exists but the following trait bounds were not satisfied: - `NotClone: std::clone::Clone` which is required by `Bar<NotClone>: std::clone::Clone` + `NotClone: std::clone::Clone` + which is required by `Bar<NotClone>: std::clone::Clone` = help: items from traits can only be used if the trait is implemented and in scope = note: the following trait defines an item `clone`, perhaps you need to implement it: candidate #1: `std::clone::Clone` diff --git a/src/test/ui/issues/issue-21596.stderr b/src/test/ui/issues/issue-21596.stderr index bbd16618049..3e0a532b2b8 100644 --- a/src/test/ui/issues/issue-21596.stderr +++ b/src/test/ui/issues/issue-21596.stderr @@ -7,7 +7,8 @@ LL | println!("{}", z.to_string()); = note: try using `<*const T>::as_ref()` to get a reference to the type behind the pointer: https://doc.rust-lang.org/std/primitive.pointer.html#method.as_ref = note: using `<*const T>::as_ref()` on a pointer which is unaligned or points to invalid or uninitialized memory is undefined behavior = note: the method `to_string` exists but the following trait bounds were not satisfied: - `*const u8: std::fmt::Display` which is required by `*const u8: std::string::ToString` + `*const u8: std::fmt::Display` + which is required by `*const u8: std::string::ToString` error: aborting due to previous error diff --git a/src/test/ui/issues/issue-31173.stderr b/src/test/ui/issues/issue-31173.stderr index ca8e63550d6..20bfdeea4b1 100644 --- a/src/test/ui/issues/issue-31173.stderr +++ b/src/test/ui/issues/issue-31173.stderr @@ -22,8 +22,10 @@ LL | pub struct TakeWhile<I, P> { | -------------------------- doesn't satisfy `<_ as std::iter::Iterator>::Item = &_` | = note: the method `collect` exists but the following trait bounds were not satisfied: - `<std::iter::TakeWhile<&mut std::vec::IntoIter<u8>, [closure@$DIR/issue-31173.rs:10:39: 13:6 found_e:_]> as std::iter::Iterator>::Item = &_` which is required by `std::iter::Cloned<std::iter::TakeWhile<&mut std::vec::IntoIter<u8>, [closure@$DIR/issue-31173.rs:10:39: 13:6 found_e:_]>>: std::iter::Iterator` - `std::iter::Cloned<std::iter::TakeWhile<&mut std::vec::IntoIter<u8>, [closure@$DIR/issue-31173.rs:10:39: 13:6 found_e:_]>>: std::iter::Iterator` which is required by `&mut std::iter::Cloned<std::iter::TakeWhile<&mut std::vec::IntoIter<u8>, [closure@$DIR/issue-31173.rs:10:39: 13:6 found_e:_]>>: std::iter::Iterator` + `<std::iter::TakeWhile<&mut std::vec::IntoIter<u8>, [closure@$DIR/issue-31173.rs:10:39: 13:6 found_e:_]> as std::iter::Iterator>::Item = &_` + which is required by `std::iter::Cloned<std::iter::TakeWhile<&mut std::vec::IntoIter<u8>, [closure@$DIR/issue-31173.rs:10:39: 13:6 found_e:_]>>: std::iter::Iterator` + `std::iter::Cloned<std::iter::TakeWhile<&mut std::vec::IntoIter<u8>, [closure@$DIR/issue-31173.rs:10:39: 13:6 found_e:_]>>: std::iter::Iterator` + which is required by `&mut std::iter::Cloned<std::iter::TakeWhile<&mut std::vec::IntoIter<u8>, [closure@$DIR/issue-31173.rs:10:39: 13:6 found_e:_]>>: std::iter::Iterator` error: aborting due to 2 previous errors diff --git a/src/test/ui/methods/method-call-err-msg.stderr b/src/test/ui/methods/method-call-err-msg.stderr index b4e54ab7783..ecb69506157 100644 --- a/src/test/ui/methods/method-call-err-msg.stderr +++ b/src/test/ui/methods/method-call-err-msg.stderr @@ -44,7 +44,8 @@ LL | .take() | ^^^^ method not found in `Foo` | = note: the method `take` exists but the following trait bounds were not satisfied: - `Foo: std::iter::Iterator` which is required by `&mut Foo: std::iter::Iterator` + `Foo: std::iter::Iterator` + which is required by `&mut Foo: std::iter::Iterator` = help: items from traits can only be used if the trait is implemented and in scope = note: the following traits define an item `take`, perhaps you need to implement one of them: candidate #1: `std::io::Read` diff --git a/src/test/ui/mismatched_types/issue-36053-2.stderr b/src/test/ui/mismatched_types/issue-36053-2.stderr index 49e61cd2327..f8c0470172d 100644 --- a/src/test/ui/mismatched_types/issue-36053-2.stderr +++ b/src/test/ui/mismatched_types/issue-36053-2.stderr @@ -13,9 +13,12 @@ LL | pub struct Filter<I, P> { | ----------------------- doesn't satisfy `_: std::iter::Iterator` | = note: the method `count` exists but the following trait bounds were not satisfied: - `<[closure@$DIR/issue-36053-2.rs:11:39: 11:53] as std::ops::FnOnce<(&&str,)>>::Output = bool` which is required by `std::iter::Filter<std::iter::Fuse<std::iter::Once<&str>>, [closure@$DIR/issue-36053-2.rs:11:39: 11:53]>: std::iter::Iterator` - `[closure@$DIR/issue-36053-2.rs:11:39: 11:53]: std::ops::FnMut<(&&str,)>` which is required by `std::iter::Filter<std::iter::Fuse<std::iter::Once<&str>>, [closure@$DIR/issue-36053-2.rs:11:39: 11:53]>: std::iter::Iterator` - `std::iter::Filter<std::iter::Fuse<std::iter::Once<&str>>, [closure@$DIR/issue-36053-2.rs:11:39: 11:53]>: std::iter::Iterator` which is required by `&mut std::iter::Filter<std::iter::Fuse<std::iter::Once<&str>>, [closure@$DIR/issue-36053-2.rs:11:39: 11:53]>: std::iter::Iterator` + `<[closure@$DIR/issue-36053-2.rs:11:39: 11:53] as std::ops::FnOnce<(&&str,)>>::Output = bool` + which is required by `std::iter::Filter<std::iter::Fuse<std::iter::Once<&str>>, [closure@$DIR/issue-36053-2.rs:11:39: 11:53]>: std::iter::Iterator` + `[closure@$DIR/issue-36053-2.rs:11:39: 11:53]: std::ops::FnMut<(&&str,)>` + which is required by `std::iter::Filter<std::iter::Fuse<std::iter::Once<&str>>, [closure@$DIR/issue-36053-2.rs:11:39: 11:53]>: std::iter::Iterator` + `std::iter::Filter<std::iter::Fuse<std::iter::Once<&str>>, [closure@$DIR/issue-36053-2.rs:11:39: 11:53]>: std::iter::Iterator` + which is required by `&mut std::iter::Filter<std::iter::Fuse<std::iter::Once<&str>>, [closure@$DIR/issue-36053-2.rs:11:39: 11:53]>: std::iter::Iterator` error[E0631]: type mismatch in closure arguments --> $DIR/issue-36053-2.rs:11:32 diff --git a/src/test/ui/suggestions/missing-trait-bounds-for-method-call.stderr b/src/test/ui/suggestions/missing-trait-bounds-for-method-call.stderr index b1b31a67650..4f6620b47c2 100644 --- a/src/test/ui/suggestions/missing-trait-bounds-for-method-call.stderr +++ b/src/test/ui/suggestions/missing-trait-bounds-for-method-call.stderr @@ -11,8 +11,10 @@ LL | self.foo(); | ^^^ method not found in `&Foo<T>` | = note: the method `foo` exists but the following trait bounds were not satisfied: - `T: Bar` which is required by `Foo<T>: Bar` - `T: std::default::Default` which is required by `Foo<T>: Bar` + `T: Bar` + which is required by `Foo<T>: Bar` + `T: std::default::Default` + which is required by `Foo<T>: Bar` = help: items from traits can only be used if the trait is implemented and in scope help: consider restricting the type parameters to satisfy the obligations | @@ -32,7 +34,8 @@ LL | self.foo(); | ^^^ method not found in `&Fin<T>` | = note: the method `foo` exists but the following trait bounds were not satisfied: - `T: std::default::Default` which is required by `Fin<T>: Bar` + `T: std::default::Default` + which is required by `Fin<T>: Bar` = help: items from traits can only be used if the trait is implemented and in scope help: consider restricting the type parameter to satisfy the obligation | diff --git a/src/test/ui/suggestions/mut-borrow-needed-by-trait.stderr b/src/test/ui/suggestions/mut-borrow-needed-by-trait.stderr index 16a03c42a4d..57a389cbb49 100644 --- a/src/test/ui/suggestions/mut-borrow-needed-by-trait.stderr +++ b/src/test/ui/suggestions/mut-borrow-needed-by-trait.stderr @@ -37,7 +37,8 @@ LL | pub struct BufWriter<W: Write> { | ------------------------------ doesn't satisfy `_: std::io::Write` | = note: the method `write_fmt` exists but the following trait bounds were not satisfied: - `&dyn std::io::Write: std::io::Write` which is required by `std::io::BufWriter<&dyn std::io::Write>: std::io::Write` + `&dyn std::io::Write: std::io::Write` + which is required by `std::io::BufWriter<&dyn std::io::Write>: std::io::Write` = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info) error: aborting due to 4 previous errors diff --git a/src/test/ui/union/union-derive-clone.stderr b/src/test/ui/union/union-derive-clone.stderr index 456e1cd83ef..fdf2393656e 100644 --- a/src/test/ui/union/union-derive-clone.stderr +++ b/src/test/ui/union/union-derive-clone.stderr @@ -23,7 +23,8 @@ LL | let w = u.clone(); | ^^^^^ method not found in `U5<CloneNoCopy>` | = note: the method `clone` exists but the following trait bounds were not satisfied: - `CloneNoCopy: std::marker::Copy` which is required by `U5<CloneNoCopy>: std::clone::Clone` + `CloneNoCopy: std::marker::Copy` + which is required by `U5<CloneNoCopy>: std::clone::Clone` = help: items from traits can only be used if the trait is implemented and in scope = note: the following trait defines an item `clone`, perhaps you need to implement it: candidate #1: `std::clone::Clone` diff --git a/src/test/ui/unique-object-noncopyable.stderr b/src/test/ui/unique-object-noncopyable.stderr index c3be38e1cf1..6a0a6c87079 100644 --- a/src/test/ui/unique-object-noncopyable.stderr +++ b/src/test/ui/unique-object-noncopyable.stderr @@ -16,8 +16,10 @@ LL | pub struct Box<T: ?Sized>(Unique<T>); | ------------------------------------- doesn't satisfy `std::boxed::Box<dyn Foo>: std::clone::Clone` | = note: the method `clone` exists but the following trait bounds were not satisfied: - `dyn Foo: std::clone::Clone` which is required by `std::boxed::Box<dyn Foo>: std::clone::Clone` - `dyn Foo: std::marker::Sized` which is required by `std::boxed::Box<dyn Foo>: std::clone::Clone` + `dyn Foo: std::clone::Clone` + which is required by `std::boxed::Box<dyn Foo>: std::clone::Clone` + `dyn Foo: std::marker::Sized` + which is required by `std::boxed::Box<dyn Foo>: std::clone::Clone` = help: items from traits can only be used if the trait is implemented and in scope = note: the following trait defines an item `clone`, perhaps you need to implement it: candidate #1: `std::clone::Clone` diff --git a/src/test/ui/unique-pinned-nocopy.stderr b/src/test/ui/unique-pinned-nocopy.stderr index fb2f4c01b63..32f751fbcf7 100644 --- a/src/test/ui/unique-pinned-nocopy.stderr +++ b/src/test/ui/unique-pinned-nocopy.stderr @@ -13,7 +13,8 @@ LL | pub struct Box<T: ?Sized>(Unique<T>); | ------------------------------------- doesn't satisfy `std::boxed::Box<R>: std::clone::Clone` | = note: the method `clone` exists but the following trait bounds were not satisfied: - `R: std::clone::Clone` which is required by `std::boxed::Box<R>: std::clone::Clone` + `R: std::clone::Clone` + which is required by `std::boxed::Box<R>: std::clone::Clone` = help: items from traits can only be used if the trait is implemented and in scope = note: the following trait defines an item `clone`, perhaps you need to implement it: candidate #1: `std::clone::Clone` |
