diff options
| author | Santiago Pastorino <spastorino@gmail.com> | 2023-03-21 16:52:15 -0300 |
|---|---|---|
| committer | Santiago Pastorino <spastorino@gmail.com> | 2023-03-29 11:27:26 -0300 |
| commit | 2ca350c776414fb09ca97311b5e0fee929c90902 (patch) | |
| tree | 8ff96046f2b74ad0071e15d59ce96eb44d86de7b | |
| parent | 66714658d0bb9cd5b3c10a876275f9646da2148f (diff) | |
| download | rust-2ca350c776414fb09ca97311b5e0fee929c90902.tar.gz rust-2ca350c776414fb09ca97311b5e0fee929c90902.zip | |
Bless some extra working tests under -Zlower-impl-trait-in-trait-to-assoc-ty
| -rw-r--r-- | tests/ui/impl-trait/in-trait/nested-rpitit.rs | 2 | ||||
| -rw-r--r-- | tests/ui/rfc-1937-termination-trait/issue-103052-2.current.stderr (renamed from tests/ui/rfc-1937-termination-trait/issue-103052-2.stderr) | 4 | ||||
| -rw-r--r-- | tests/ui/rfc-1937-termination-trait/issue-103052-2.next.stderr | 15 | ||||
| -rw-r--r-- | tests/ui/rfc-1937-termination-trait/issue-103052-2.rs | 6 |
4 files changed, 24 insertions, 3 deletions
diff --git a/tests/ui/impl-trait/in-trait/nested-rpitit.rs b/tests/ui/impl-trait/in-trait/nested-rpitit.rs index 65285e3a3cc..36020753726 100644 --- a/tests/ui/impl-trait/in-trait/nested-rpitit.rs +++ b/tests/ui/impl-trait/in-trait/nested-rpitit.rs @@ -1,4 +1,6 @@ // check-pass +// [next] compile-flags: -Zlower-impl-trait-in-trait-to-assoc-ty +// revisions: current next #![feature(return_position_impl_trait_in_trait)] #![allow(incomplete_features)] diff --git a/tests/ui/rfc-1937-termination-trait/issue-103052-2.stderr b/tests/ui/rfc-1937-termination-trait/issue-103052-2.current.stderr index a700c72ea68..f72b3ab0234 100644 --- a/tests/ui/rfc-1937-termination-trait/issue-103052-2.stderr +++ b/tests/ui/rfc-1937-termination-trait/issue-103052-2.current.stderr @@ -1,11 +1,11 @@ error[E0277]: the trait bound `Something: Termination` is not satisfied - --> $DIR/issue-103052-2.rs:12:22 + --> $DIR/issue-103052-2.rs:15:22 | LL | fn main() -> Something { | ^^^^^^^^^ the trait `Termination` is not implemented for `Something` | note: required by a bound in `Main::main::{opaque#0}` - --> $DIR/issue-103052-2.rs:6:27 + --> $DIR/issue-103052-2.rs:9:27 | LL | fn main() -> impl std::process::Termination; | ^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `Main::main::{opaque#0}` diff --git a/tests/ui/rfc-1937-termination-trait/issue-103052-2.next.stderr b/tests/ui/rfc-1937-termination-trait/issue-103052-2.next.stderr new file mode 100644 index 00000000000..8b01941b4c6 --- /dev/null +++ b/tests/ui/rfc-1937-termination-trait/issue-103052-2.next.stderr @@ -0,0 +1,15 @@ +error[E0277]: the trait bound `Something: Termination` is not satisfied + --> $DIR/issue-103052-2.rs:15:22 + | +LL | fn main() -> Something { + | ^^^^^^^^^ the trait `Termination` is not implemented for `Something` + | +note: required by a bound in `Main::{opaque#0}` + --> $DIR/issue-103052-2.rs:9:27 + | +LL | fn main() -> impl std::process::Termination; + | ^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `Main::{opaque#0}` + +error: aborting due to previous error + +For more information about this error, try `rustc --explain E0277`. diff --git a/tests/ui/rfc-1937-termination-trait/issue-103052-2.rs b/tests/ui/rfc-1937-termination-trait/issue-103052-2.rs index fa9182b6dee..ca5fa6df2a6 100644 --- a/tests/ui/rfc-1937-termination-trait/issue-103052-2.rs +++ b/tests/ui/rfc-1937-termination-trait/issue-103052-2.rs @@ -1,3 +1,6 @@ +// [next] compile-flags: -Zlower-impl-trait-in-trait-to-assoc-ty +// revisions: current next + #![feature(return_position_impl_trait_in_trait)] #![allow(incomplete_features)] @@ -9,7 +12,8 @@ mod child { struct Something; impl Main for () { - fn main() -> Something { //~ ERROR the trait bound `Something: Termination` is not satisfied + fn main() -> Something { + //~^ ERROR the trait bound `Something: Termination` is not satisfied Something } } |
