about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMichael Goulet <michael@errs.io>2024-03-10 22:25:32 -0400
committerMichael Goulet <michael@errs.io>2024-03-10 23:23:46 -0400
commit01e6b43a0735aaff7c127a39984ecd9638232edf (patch)
tree90a39c5597443cf1b7ce4724c01b5f6e7ed68aa1
parent383051092f02c2eb2b99e50a38da7a04f28bbb65 (diff)
downloadrust-01e6b43a0735aaff7c127a39984ecd9638232edf.tar.gz
rust-01e6b43a0735aaff7c127a39984ecd9638232edf.zip
Mark some next-solver-behavior tests explicitly with revisions
-rw-r--r--tests/ui/associated-inherent-types/bugs/wf-check-skipped.next.stderr8
-rw-r--r--tests/ui/associated-inherent-types/bugs/wf-check-skipped.rs11
-rw-r--r--tests/ui/associated-types/defaults-unsound-62211-1.current.stderr (renamed from tests/ui/associated-types/defaults-unsound-62211-1.stderr)16
-rw-r--r--tests/ui/associated-types/defaults-unsound-62211-1.next.stderr13
-rw-r--r--tests/ui/associated-types/defaults-unsound-62211-1.rs14
-rw-r--r--tests/ui/associated-types/defaults-unsound-62211-2.current.stderr (renamed from tests/ui/associated-types/defaults-unsound-62211-2.stderr)16
-rw-r--r--tests/ui/associated-types/defaults-unsound-62211-2.next.stderr13
-rw-r--r--tests/ui/associated-types/defaults-unsound-62211-2.rs14
-rw-r--r--tests/ui/coherence/indirect-impl-for-trait-obj-coherence.next.stderr9
-rw-r--r--tests/ui/coherence/indirect-impl-for-trait-obj-coherence.rs8
-rw-r--r--tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.current.stderr (renamed from tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.stderr)6
-rw-r--r--tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.rs6
-rw-r--r--tests/ui/generic-associated-types/issue-90014-tait2.next-solver.stderr15
-rw-r--r--tests/ui/traits/pointee-tail-is-generic.rs10
-rw-r--r--tests/ui/typeck/issue-103899.rs12
-rw-r--r--tests/ui/wf/wf-normalization-sized.next.stderr30
-rw-r--r--tests/ui/wf/wf-normalization-sized.rs11
17 files changed, 168 insertions, 44 deletions
diff --git a/tests/ui/associated-inherent-types/bugs/wf-check-skipped.next.stderr b/tests/ui/associated-inherent-types/bugs/wf-check-skipped.next.stderr
new file mode 100644
index 00000000000..77fbaf52934
--- /dev/null
+++ b/tests/ui/associated-inherent-types/bugs/wf-check-skipped.next.stderr
@@ -0,0 +1,8 @@
+error: the type `Foo::Bar<Vec<[u32]>>` is not well-formed
+  --> $DIR/wf-check-skipped.rs:17:14
+   |
+LL | fn main() -> Foo::Bar::<Vec<[u32]>> {}
+   |              ^^^^^^^^^^^^^^^^^^^^^^
+
+error: aborting due to 1 previous error
+
diff --git a/tests/ui/associated-inherent-types/bugs/wf-check-skipped.rs b/tests/ui/associated-inherent-types/bugs/wf-check-skipped.rs
index 3159500393e..5b812a2295e 100644
--- a/tests/ui/associated-inherent-types/bugs/wf-check-skipped.rs
+++ b/tests/ui/associated-inherent-types/bugs/wf-check-skipped.rs
@@ -1,11 +1,13 @@
-//@ known-bug: #100041
-//@ check-pass
+//@ revisions: current next
+//@[next] compile-flags: -Znext-solver
+//@ ignore-compare-mode-next-solver (explicit revisions)
+//@[current] known-bug: #100041
+//@[current] check-pass
+// FIXME(inherent_associated_types): This should fail.
 
 #![feature(inherent_associated_types)]
 #![allow(incomplete_features)]
 
-// FIXME(inherent_associated_types): This should fail.
-
 struct Foo;
 
 impl Foo {
@@ -13,3 +15,4 @@ impl Foo {
 }
 
 fn main() -> Foo::Bar::<Vec<[u32]>> {}
+//[next]~^ ERROR the type `Foo::Bar<Vec<[u32]>>` is not well-formed
diff --git a/tests/ui/associated-types/defaults-unsound-62211-1.stderr b/tests/ui/associated-types/defaults-unsound-62211-1.current.stderr
index 5cd1cb4a1a7..9d52e923ade 100644
--- a/tests/ui/associated-types/defaults-unsound-62211-1.stderr
+++ b/tests/ui/associated-types/defaults-unsound-62211-1.current.stderr
@@ -1,12 +1,12 @@
 error[E0277]: `Self` doesn't implement `std::fmt::Display`
-  --> $DIR/defaults-unsound-62211-1.rs:20:96
+  --> $DIR/defaults-unsound-62211-1.rs:26:96
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                                ^^^^ `Self` cannot be formatted with the default formatter
    |
    = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
 note: required by a bound in `UncheckedCopy::Output`
-  --> $DIR/defaults-unsound-62211-1.rs:20:86
+  --> $DIR/defaults-unsound-62211-1.rs:26:86
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                      ^^^^^^^ required by this bound in `UncheckedCopy::Output`
@@ -16,13 +16,13 @@ LL | trait UncheckedCopy: Sized + std::fmt::Display {
    |                            +++++++++++++++++++
 
 error[E0277]: cannot add-assign `&'static str` to `Self`
-  --> $DIR/defaults-unsound-62211-1.rs:20:96
+  --> $DIR/defaults-unsound-62211-1.rs:26:96
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                                ^^^^ no implementation for `Self += &'static str`
    |
 note: required by a bound in `UncheckedCopy::Output`
-  --> $DIR/defaults-unsound-62211-1.rs:20:47
+  --> $DIR/defaults-unsound-62211-1.rs:26:47
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                               ^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `UncheckedCopy::Output`
@@ -32,13 +32,13 @@ LL | trait UncheckedCopy: Sized + AddAssign<&'static str> {
    |                            +++++++++++++++++++++++++
 
 error[E0277]: the trait bound `Self: Deref` is not satisfied
-  --> $DIR/defaults-unsound-62211-1.rs:20:96
+  --> $DIR/defaults-unsound-62211-1.rs:26:96
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                                ^^^^ the trait `Deref` is not implemented for `Self`
    |
 note: required by a bound in `UncheckedCopy::Output`
-  --> $DIR/defaults-unsound-62211-1.rs:20:25
+  --> $DIR/defaults-unsound-62211-1.rs:26:25
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                         ^^^^^^^^^^^^^^^^^^^ required by this bound in `UncheckedCopy::Output`
@@ -48,13 +48,13 @@ LL | trait UncheckedCopy: Sized + Deref {
    |                            +++++++
 
 error[E0277]: the trait bound `Self: Copy` is not satisfied
-  --> $DIR/defaults-unsound-62211-1.rs:20:96
+  --> $DIR/defaults-unsound-62211-1.rs:26:96
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                                ^^^^ the trait `Copy` is not implemented for `Self`
    |
 note: required by a bound in `UncheckedCopy::Output`
-  --> $DIR/defaults-unsound-62211-1.rs:20:18
+  --> $DIR/defaults-unsound-62211-1.rs:26:18
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                  ^^^^ required by this bound in `UncheckedCopy::Output`
diff --git a/tests/ui/associated-types/defaults-unsound-62211-1.next.stderr b/tests/ui/associated-types/defaults-unsound-62211-1.next.stderr
new file mode 100644
index 00000000000..834ae00a8d8
--- /dev/null
+++ b/tests/ui/associated-types/defaults-unsound-62211-1.next.stderr
@@ -0,0 +1,13 @@
+warning: calls to `std::mem::drop` with a value that implements `Copy` does nothing
+  --> $DIR/defaults-unsound-62211-1.rs:52:5
+   |
+LL |     drop(origin);
+   |     ^^^^^------^
+   |          |
+   |          argument has type `<T as UncheckedCopy>::Output`
+   |
+   = note: use `let _ = ...` to ignore the expression or result
+   = note: `#[warn(dropping_copy_types)]` on by default
+
+warning: 1 warning emitted
+
diff --git a/tests/ui/associated-types/defaults-unsound-62211-1.rs b/tests/ui/associated-types/defaults-unsound-62211-1.rs
index fa6a208b4f1..d9cf5aa97ac 100644
--- a/tests/ui/associated-types/defaults-unsound-62211-1.rs
+++ b/tests/ui/associated-types/defaults-unsound-62211-1.rs
@@ -1,3 +1,9 @@
+//@ revisions: current next
+//@[next] compile-flags: -Znext-solver
+//@ ignore-compare-mode-next-solver (explicit revisions)
+//@[next] known-bug: rust-lang/trait-system-refactor-initiative#46
+//@[next] check-pass
+
 //! Regression test for https://github.com/rust-lang/rust/issues/62211
 //!
 //! The old implementation of defaults did not check whether the provided
@@ -18,10 +24,10 @@ trait UncheckedCopy: Sized {
     // This Output is said to be Copy. Yet we default to Self
     // and it's accepted, not knowing if Self ineed is Copy
     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
-    //~^ ERROR the trait bound `Self: Copy` is not satisfied
-    //~| ERROR the trait bound `Self: Deref` is not satisfied
-    //~| ERROR cannot add-assign `&'static str` to `Self`
-    //~| ERROR `Self` doesn't implement `std::fmt::Display`
+    //[current]~^ ERROR the trait bound `Self: Copy` is not satisfied
+    //[current]~| ERROR the trait bound `Self: Deref` is not satisfied
+    //[current]~| ERROR cannot add-assign `&'static str` to `Self`
+    //[current]~| ERROR `Self` doesn't implement `std::fmt::Display`
 
     // We said the Output type was Copy, so we can Copy it freely!
     fn unchecked_copy(other: &Self::Output) -> Self::Output {
diff --git a/tests/ui/associated-types/defaults-unsound-62211-2.stderr b/tests/ui/associated-types/defaults-unsound-62211-2.current.stderr
index 89319bb7563..4fd2ca6408a 100644
--- a/tests/ui/associated-types/defaults-unsound-62211-2.stderr
+++ b/tests/ui/associated-types/defaults-unsound-62211-2.current.stderr
@@ -1,12 +1,12 @@
 error[E0277]: `Self` doesn't implement `std::fmt::Display`
-  --> $DIR/defaults-unsound-62211-2.rs:20:96
+  --> $DIR/defaults-unsound-62211-2.rs:26:96
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                                ^^^^ `Self` cannot be formatted with the default formatter
    |
    = note: in format strings you may be able to use `{:?}` (or {:#?} for pretty-print) instead
 note: required by a bound in `UncheckedCopy::Output`
-  --> $DIR/defaults-unsound-62211-2.rs:20:86
+  --> $DIR/defaults-unsound-62211-2.rs:26:86
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                      ^^^^^^^ required by this bound in `UncheckedCopy::Output`
@@ -16,13 +16,13 @@ LL | trait UncheckedCopy: Sized + std::fmt::Display {
    |                            +++++++++++++++++++
 
 error[E0277]: cannot add-assign `&'static str` to `Self`
-  --> $DIR/defaults-unsound-62211-2.rs:20:96
+  --> $DIR/defaults-unsound-62211-2.rs:26:96
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                                ^^^^ no implementation for `Self += &'static str`
    |
 note: required by a bound in `UncheckedCopy::Output`
-  --> $DIR/defaults-unsound-62211-2.rs:20:47
+  --> $DIR/defaults-unsound-62211-2.rs:26:47
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                               ^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `UncheckedCopy::Output`
@@ -32,13 +32,13 @@ LL | trait UncheckedCopy: Sized + AddAssign<&'static str> {
    |                            +++++++++++++++++++++++++
 
 error[E0277]: the trait bound `Self: Deref` is not satisfied
-  --> $DIR/defaults-unsound-62211-2.rs:20:96
+  --> $DIR/defaults-unsound-62211-2.rs:26:96
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                                ^^^^ the trait `Deref` is not implemented for `Self`
    |
 note: required by a bound in `UncheckedCopy::Output`
-  --> $DIR/defaults-unsound-62211-2.rs:20:25
+  --> $DIR/defaults-unsound-62211-2.rs:26:25
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                         ^^^^^^^^^^^^^^^^^^^ required by this bound in `UncheckedCopy::Output`
@@ -48,13 +48,13 @@ LL | trait UncheckedCopy: Sized + Deref {
    |                            +++++++
 
 error[E0277]: the trait bound `Self: Copy` is not satisfied
-  --> $DIR/defaults-unsound-62211-2.rs:20:96
+  --> $DIR/defaults-unsound-62211-2.rs:26:96
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                                                                                                ^^^^ the trait `Copy` is not implemented for `Self`
    |
 note: required by a bound in `UncheckedCopy::Output`
-  --> $DIR/defaults-unsound-62211-2.rs:20:18
+  --> $DIR/defaults-unsound-62211-2.rs:26:18
    |
 LL |     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
    |                  ^^^^ required by this bound in `UncheckedCopy::Output`
diff --git a/tests/ui/associated-types/defaults-unsound-62211-2.next.stderr b/tests/ui/associated-types/defaults-unsound-62211-2.next.stderr
new file mode 100644
index 00000000000..0f944a18ed5
--- /dev/null
+++ b/tests/ui/associated-types/defaults-unsound-62211-2.next.stderr
@@ -0,0 +1,13 @@
+warning: calls to `std::mem::drop` with a value that implements `Copy` does nothing
+  --> $DIR/defaults-unsound-62211-2.rs:52:5
+   |
+LL |     drop(origin);
+   |     ^^^^^------^
+   |          |
+   |          argument has type `<T as UncheckedCopy>::Output`
+   |
+   = note: use `let _ = ...` to ignore the expression or result
+   = note: `#[warn(dropping_copy_types)]` on by default
+
+warning: 1 warning emitted
+
diff --git a/tests/ui/associated-types/defaults-unsound-62211-2.rs b/tests/ui/associated-types/defaults-unsound-62211-2.rs
index c13ec776afe..6cbac1bf236 100644
--- a/tests/ui/associated-types/defaults-unsound-62211-2.rs
+++ b/tests/ui/associated-types/defaults-unsound-62211-2.rs
@@ -1,3 +1,9 @@
+//@ revisions: current next
+//@[next] compile-flags: -Znext-solver
+//@ ignore-compare-mode-next-solver (explicit revisions)
+//@[next] known-bug: rust-lang/trait-system-refactor-initiative#46
+//@[next] check-pass
+
 //! Regression test for https://github.com/rust-lang/rust/issues/62211
 //!
 //! The old implementation of defaults did not check whether the provided
@@ -18,10 +24,10 @@ trait UncheckedCopy: Sized {
     // This Output is said to be Copy. Yet we default to Self
     // and it's accepted, not knowing if Self ineed is Copy
     type Output: Copy + Deref<Target = str> + AddAssign<&'static str> + From<Self> + Display = Self;
-    //~^ ERROR the trait bound `Self: Copy` is not satisfied
-    //~| ERROR the trait bound `Self: Deref` is not satisfied
-    //~| ERROR cannot add-assign `&'static str` to `Self`
-    //~| ERROR `Self` doesn't implement `std::fmt::Display`
+    //[current]~^ ERROR the trait bound `Self: Copy` is not satisfied
+    //[current]~| ERROR the trait bound `Self: Deref` is not satisfied
+    //[current]~| ERROR cannot add-assign `&'static str` to `Self`
+    //[current]~| ERROR `Self` doesn't implement `std::fmt::Display`
 
     // We said the Output type was Copy, so we can Copy it freely!
     fn unchecked_copy(other: &Self::Output) -> Self::Output {
diff --git a/tests/ui/coherence/indirect-impl-for-trait-obj-coherence.next.stderr b/tests/ui/coherence/indirect-impl-for-trait-obj-coherence.next.stderr
new file mode 100644
index 00000000000..6e41561f1a7
--- /dev/null
+++ b/tests/ui/coherence/indirect-impl-for-trait-obj-coherence.next.stderr
@@ -0,0 +1,9 @@
+error[E0284]: type annotations needed: cannot satisfy `<dyn Object<U, Output = T> as Object<U>>::Output == T`
+  --> $DIR/indirect-impl-for-trait-obj-coherence.rs:25:41
+   |
+LL |     foo::<dyn Object<U, Output = T>, U>(x)
+   |                                         ^ cannot satisfy `<dyn Object<U, Output = T> as Object<U>>::Output == T`
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0284`.
diff --git a/tests/ui/coherence/indirect-impl-for-trait-obj-coherence.rs b/tests/ui/coherence/indirect-impl-for-trait-obj-coherence.rs
index 201a46a166a..0b66a6e7830 100644
--- a/tests/ui/coherence/indirect-impl-for-trait-obj-coherence.rs
+++ b/tests/ui/coherence/indirect-impl-for-trait-obj-coherence.rs
@@ -1,5 +1,8 @@
-//@ check-pass
-//@ known-bug: #57893
+//@ revisions: current next
+//@[next] compile-flags: -Znext-solver
+//@ ignore-compare-mode-next-solver (explicit revisions)
+//@[current] check-pass
+//@[current] known-bug: #57893
 
 // Should fail. Because we see an impl that uses a certain associated type, we
 // type-check assuming that impl is used. However, this conflicts with the
@@ -20,6 +23,7 @@ fn foo<T: ?Sized, U>(x: <T as Object<U>>::Output) -> U {
 #[allow(dead_code)]
 fn transmute<T, U>(x: T) -> U {
     foo::<dyn Object<U, Output = T>, U>(x)
+    //[next]~^ ERROR type annotations needed: cannot satisfy `<dyn Object<U, Output = T> as Object<U>>::Output == T`
 }
 
 fn main() {}
diff --git a/tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.stderr b/tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.current.stderr
index 314a5509da8..2097115af00 100644
--- a/tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.stderr
+++ b/tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.current.stderr
@@ -1,16 +1,16 @@
 error[E0277]: the trait bound `<Self as Foo>::Bar<()>: Eq<i32>` is not satisfied
-  --> $DIR/assume-gat-normalization-for-nested-goals.rs:6:30
+  --> $DIR/assume-gat-normalization-for-nested-goals.rs:10:30
    |
 LL |     type Bar<T>: Baz<Self> = i32;
    |                              ^^^ the trait `Eq<i32>` is not implemented for `<Self as Foo>::Bar<()>`, which is required by `i32: Baz<Self>`
    |
 note: required for `i32` to implement `Baz<Self>`
-  --> $DIR/assume-gat-normalization-for-nested-goals.rs:13:23
+  --> $DIR/assume-gat-normalization-for-nested-goals.rs:17:23
    |
 LL | impl<T: Foo + ?Sized> Baz<T> for i32 where T::Bar<()>: Eq<i32> {}
    |                       ^^^^^^     ^^^                   ------- unsatisfied trait bound introduced here
 note: required by a bound in `Foo::Bar`
-  --> $DIR/assume-gat-normalization-for-nested-goals.rs:6:18
+  --> $DIR/assume-gat-normalization-for-nested-goals.rs:10:18
    |
 LL |     type Bar<T>: Baz<Self> = i32;
    |                  ^^^^^^^^^ required by this bound in `Foo::Bar`
diff --git a/tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.rs b/tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.rs
index fade3c441ab..56b50594e52 100644
--- a/tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.rs
+++ b/tests/ui/generic-associated-types/assume-gat-normalization-for-nested-goals.rs
@@ -1,4 +1,8 @@
-//@ known-bug: #117606
+//@ revisions: current next
+//@[next] compile-flags: -Znext-solver
+//@ ignore-compare-mode-next-solver (explicit revisions)
+//@[current] known-bug: #117606
+//@[next] check-pass
 
 #![feature(associated_type_defaults)]
 
diff --git a/tests/ui/generic-associated-types/issue-90014-tait2.next-solver.stderr b/tests/ui/generic-associated-types/issue-90014-tait2.next-solver.stderr
new file mode 100644
index 00000000000..85c5dad7fc0
--- /dev/null
+++ b/tests/ui/generic-associated-types/issue-90014-tait2.next-solver.stderr
@@ -0,0 +1,15 @@
+error[E0308]: mismatched types
+  --> $DIR/issue-90014-tait2.rs:27:9
+   |
+LL |     fn make_fut(&self) -> Box<dyn for<'a> Trait<'a, Thing = Fut<'a>>> {
+   |                           ------------------------------------------- expected `Box<(dyn for<'a> Trait<'a, Thing = Fut<'a>> + 'static)>` because of return type
+LL |         Box::new((async { () },))
+   |         ^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Box<dyn Trait<'a, Thing = Fut<'_>>>`, found `Box<(...,)>`
+   |
+   = note: expected struct `Box<(dyn for<'a> Trait<'a, Thing = Fut<'a>> + 'static)>`
+              found struct `Box<({async block@$DIR/issue-90014-tait2.rs:27:19: 27:31},)>`
+   = help: `({async block@$DIR/issue-90014-tait2.rs:27:19: 27:31},)` implements `Trait` so you could box the found value and coerce it to the trait object `Box<dyn Trait>`, you will have to change the expected type as well
+
+error: aborting due to 1 previous error
+
+For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/traits/pointee-tail-is-generic.rs b/tests/ui/traits/pointee-tail-is-generic.rs
index e33b2b2f2bc..14bdf0880c7 100644
--- a/tests/ui/traits/pointee-tail-is-generic.rs
+++ b/tests/ui/traits/pointee-tail-is-generic.rs
@@ -4,10 +4,12 @@
 #![feature(ptr_metadata)]
 #![feature(type_alias_impl_trait)]
 
-type Opaque = impl std::future::Future;
+mod opaque {
+    pub type Opaque = impl std::future::Future;
 
-fn opaque() -> Opaque {
-    async {}
+    fn opaque() -> Opaque {
+        async {}
+    }
 }
 
 fn a<T>() {
@@ -16,7 +18,7 @@ fn a<T>() {
     // tail of ADT (which is a type param) is known to be sized
     is_thin::<std::cell::Cell<T>>();
     // opaque type is known to be sized
-    is_thin::<Opaque>();
+    is_thin::<opaque::Opaque>();
 }
 
 fn a2<T: Iterator>() {
diff --git a/tests/ui/typeck/issue-103899.rs b/tests/ui/typeck/issue-103899.rs
index 5876a34ef55..38882e9dc54 100644
--- a/tests/ui/typeck/issue-103899.rs
+++ b/tests/ui/typeck/issue-103899.rs
@@ -1,7 +1,11 @@
-//@ check-fail
-//@ failure-status: 101
-//@ dont-check-compiler-stderr
-//@ known-bug: #103899
+//@ revisions: current next
+//@[next] compile-flags: -Znext-solver
+//@[next] check-pass
+//@ ignore-compare-mode-next-solver (explicit revisions)
+//@[current] check-fail
+//@[current] failure-status: 101
+//@[current] dont-check-compiler-stderr
+//@[current] known-bug: #103899
 
 trait BaseWithAssoc {
     type Assoc;
diff --git a/tests/ui/wf/wf-normalization-sized.next.stderr b/tests/ui/wf/wf-normalization-sized.next.stderr
new file mode 100644
index 00000000000..599b1f3d45e
--- /dev/null
+++ b/tests/ui/wf/wf-normalization-sized.next.stderr
@@ -0,0 +1,30 @@
+error: the type `<[[[[[[u8]]]]]] as WellUnformed>::RequestNormalize` is not well-formed
+  --> $DIR/wf-normalization-sized.rs:19:10
+   |
+LL | const _: <[[[[[[u8]]]]]] as WellUnformed>::RequestNormalize = ();
+   |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+error: the type `<[[[[[[u8]]]]]] as WellUnformed>::RequestNormalize` is not well-formed
+  --> $DIR/wf-normalization-sized.rs:19:10
+   |
+LL | const _: <[[[[[[u8]]]]]] as WellUnformed>::RequestNormalize = ();
+   |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
+
+error: the type `<Vec<str> as WellUnformed>::RequestNormalize` is not well-formed
+  --> $DIR/wf-normalization-sized.rs:22:10
+   |
+LL | const _: <Vec<str> as WellUnformed>::RequestNormalize = ();
+   |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+error: the type `<Vec<str> as WellUnformed>::RequestNormalize` is not well-formed
+  --> $DIR/wf-normalization-sized.rs:22:10
+   |
+LL | const _: <Vec<str> as WellUnformed>::RequestNormalize = ();
+   |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   |
+   = note: duplicate diagnostic emitted due to `-Z deduplicate-diagnostics=no`
+
+error: aborting due to 4 previous errors
+
diff --git a/tests/ui/wf/wf-normalization-sized.rs b/tests/ui/wf/wf-normalization-sized.rs
index e14be6b62bb..e6e24ff9e85 100644
--- a/tests/ui/wf/wf-normalization-sized.rs
+++ b/tests/ui/wf/wf-normalization-sized.rs
@@ -1,5 +1,8 @@
-//@ check-pass
-//@ known-bug: #100041
+//@ revisions: current next
+//@[next] compile-flags: -Znext-solver
+//@ ignore-compare-mode-next-solver (explicit revisions)
+//@[current] check-pass
+//@[current] known-bug: #100041
 
 // Should fail. Normalization can bypass well-formedness checking.
 // `[[[[[[u8]]]]]]` is not a well-formed type since size of type `[u8]` cannot
@@ -14,6 +17,10 @@ impl<T: ?Sized> WellUnformed for T {
 }
 
 const _: <[[[[[[u8]]]]]] as WellUnformed>::RequestNormalize = ();
+//[next]~^ the type
+//[next]~| the type
 const _: <Vec<str> as WellUnformed>::RequestNormalize = ();
+//[next]~^ the type
+//[next]~| the type
 
 fn main() {}