Skip to content

Commit 791a98e

Browse files
committed
Update ui test suite to nightly-2021-10-07
1 parent ed234d4 commit 791a98e

File tree

5 files changed

+75
-39
lines changed

5 files changed

+75
-39
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ jobs:
2121
- uses: dtolnay/rust-toolchain@master
2222
with:
2323
toolchain: ${{matrix.rust}}
24+
components: rust-src
2425
- run: cargo test --all
2526
env:
2627
RUSTFLAGS: ${{matrix.rustflags}}

rust-toolchain.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[toolchain]
2+
components = ["rust-src"]

tests/ui/no-display.stderr

Lines changed: 21 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,23 @@
11
error[E0599]: the method `as_display` exists for reference `&NoDisplay`, but its trait bounds were not satisfied
2-
--> $DIR/no-display.rs:7:9
3-
|
4-
4 | struct NoDisplay;
5-
| ----------------- doesn't satisfy `NoDisplay: std::fmt::Display`
2+
--> $DIR/tests/ui/no-display.rs:7:9
3+
|
4+
4 | struct NoDisplay;
5+
| ----------------- doesn't satisfy `NoDisplay: std::fmt::Display`
66
...
7-
7 | #[error("thread: {thread}")]
8-
| ^^^^^^^^^^^^^^^^^^ method cannot be called on `&NoDisplay` due to unsatisfied trait bounds
9-
|
10-
= note: the following trait bounds were not satisfied:
11-
`NoDisplay: std::fmt::Display`
12-
which is required by `&NoDisplay: DisplayAsDisplay`
7+
7 | #[error("thread: {thread}")]
8+
| ^^^^^^^^^^^^^^^^^^ method cannot be called on `&NoDisplay` due to unsatisfied trait bounds
9+
|
10+
= note: the following trait bounds were not satisfied:
11+
`NoDisplay: std::fmt::Display`
12+
which is required by `&NoDisplay: DisplayAsDisplay`
13+
note: the following trait must be implemented
14+
--> $RUST/core/src/fmt/mod.rs
15+
|
16+
| / pub trait Display {
17+
| | /// Formats the value using the given formatter.
18+
| | ///
19+
| | /// # Examples
20+
... |
21+
| | fn fmt(&self, f: &mut Formatter<'_>) -> Result;
22+
| | }
23+
| |_^

tests/ui/source-enum-not-error.stderr

Lines changed: 26 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,28 @@
11
error[E0599]: the method `as_dyn_error` exists for reference `&NotError`, but its trait bounds were not satisfied
2-
--> $DIR/source-enum-not-error.rs:10:9
3-
|
4-
4 | pub struct NotError;
5-
| --------------------
6-
| |
7-
| doesn't satisfy `NotError: AsDynError`
8-
| doesn't satisfy `NotError: std::error::Error`
2+
--> $DIR/tests/ui/source-enum-not-error.rs:10:9
3+
|
4+
4 | pub struct NotError;
5+
| --------------------
6+
| |
7+
| doesn't satisfy `NotError: AsDynError`
8+
| doesn't satisfy `NotError: std::error::Error`
99
...
10-
10 | source: NotError,
11-
| ^^^^^^ method cannot be called on `&NotError` due to unsatisfied trait bounds
12-
|
13-
= note: the following trait bounds were not satisfied:
14-
`NotError: std::error::Error`
15-
which is required by `NotError: AsDynError`
16-
`&NotError: std::error::Error`
17-
which is required by `&NotError: AsDynError`
10+
10 | source: NotError,
11+
| ^^^^^^ method cannot be called on `&NotError` due to unsatisfied trait bounds
12+
|
13+
= note: the following trait bounds were not satisfied:
14+
`NotError: std::error::Error`
15+
which is required by `NotError: AsDynError`
16+
`&NotError: std::error::Error`
17+
which is required by `&NotError: AsDynError`
18+
note: the following trait must be implemented
19+
--> $RUST/std/src/error.rs
20+
|
21+
| / pub trait Error: Debug + Display {
22+
| | /// The lower-level source of this error, if any.
23+
| | ///
24+
| | /// # Examples
25+
... |
26+
| | }
27+
| | }
28+
| |_^
Lines changed: 25 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,27 @@
11
error[E0599]: the method `as_dyn_error` exists for struct `NotError`, but its trait bounds were not satisfied
2-
--> $DIR/source-struct-not-error.rs:9:5
3-
|
4-
4 | struct NotError;
5-
| ----------------
6-
| |
7-
| method `as_dyn_error` not found for this
8-
| doesn't satisfy `NotError: AsDynError`
9-
| doesn't satisfy `NotError: std::error::Error`
2+
--> $DIR/tests/ui/source-struct-not-error.rs:9:5
3+
|
4+
4 | struct NotError;
5+
| ----------------
6+
| |
7+
| method `as_dyn_error` not found for this
8+
| doesn't satisfy `NotError: AsDynError`
9+
| doesn't satisfy `NotError: std::error::Error`
1010
...
11-
9 | source: NotError,
12-
| ^^^^^^ method cannot be called on `NotError` due to unsatisfied trait bounds
13-
|
14-
= note: the following trait bounds were not satisfied:
15-
`NotError: std::error::Error`
16-
which is required by `NotError: AsDynError`
11+
9 | source: NotError,
12+
| ^^^^^^ method cannot be called on `NotError` due to unsatisfied trait bounds
13+
|
14+
= note: the following trait bounds were not satisfied:
15+
`NotError: std::error::Error`
16+
which is required by `NotError: AsDynError`
17+
note: the following trait must be implemented
18+
--> $RUST/std/src/error.rs
19+
|
20+
| / pub trait Error: Debug + Display {
21+
| | /// The lower-level source of this error, if any.
22+
| | ///
23+
| | /// # Examples
24+
... |
25+
| | }
26+
| | }
27+
| |_^

0 commit comments

Comments
 (0)