add new solver revisions to already fixed normalization tests

There were fixed by https://github.com/rust-lang/rust/pull/140672
This commit is contained in:
Rémy Rakic
2026-05-06 16:29:19 +02:00
parent e95e73209f
commit e2ea0ba07a
8 changed files with 142 additions and 9 deletions
@@ -1,5 +1,5 @@
error: overflow evaluating associated type `T::This`
--> $DIR/normalization-overflow.rs:9:5
--> $DIR/normalization-overflow.rs:14:5
|
LL | type This = Self::This;
| ^^^^^^^^^
@@ -0,0 +1,9 @@
error[E0271]: type mismatch resolving `T::This normalizes-to _`
--> $DIR/normalization-overflow.rs:14:5
|
LL | type This = Self::This;
| ^^^^^^^^^ types differ
error: aborting due to 1 previous error
For more information about this error, try `rustc --explain E0271`.
@@ -1,12 +1,19 @@
#![feature(inherent_associated_types)]
//@ revisions: current next
//@ ignore-compare-mode-next-solver (explicit revisions)
//@ [next] compile-flags: -Znext-solver
#![feature(inherent_associated_types, rustc_attrs)]
#![allow(incomplete_features)]
#![rustc_no_implicit_bounds]
// FIXME(fmease): I'd prefer to report a cycle error here instead of an overflow one.
struct T;
impl T {
type This = Self::This; //~ ERROR overflow evaluating associated type `T::This`
type This = Self::This;
//[current]~^ ERROR: overflow evaluating associated type `T::This`
//[next]~^^ ERROR: type mismatch resolving `T::This normalizes-to _`
}
fn main() {}
@@ -0,0 +1,21 @@
error[E0271]: type mismatch resolving `X3 normalizes-to _`
--> $DIR/infinite-type-alias-mutual-recursion.rs:12:1
|
LL | type X1 = X2;
| ^^^^^^^ types differ
error[E0271]: type mismatch resolving `X1 normalizes-to _`
--> $DIR/infinite-type-alias-mutual-recursion.rs:16:1
|
LL | type X2 = X3;
| ^^^^^^^ types differ
error[E0271]: type mismatch resolving `X2 normalizes-to _`
--> $DIR/infinite-type-alias-mutual-recursion.rs:19:1
|
LL | type X3 = X1;
| ^^^^^^^ types differ
error: aborting due to 3 previous errors
For more information about this error, try `rustc --explain E0271`.
@@ -0,0 +1,27 @@
error[E0275]: overflow normalizing the type alias `X2`
--> $DIR/infinite-type-alias-mutual-recursion.rs:12:1
|
LL | type X1 = X2;
| ^^^^^^^
|
= note: in case this is a recursive type alias, consider using a struct, enum, or union instead
error[E0275]: overflow normalizing the type alias `X3`
--> $DIR/infinite-type-alias-mutual-recursion.rs:16:1
|
LL | type X2 = X3;
| ^^^^^^^
|
= note: in case this is a recursive type alias, consider using a struct, enum, or union instead
error[E0275]: overflow normalizing the type alias `X1`
--> $DIR/infinite-type-alias-mutual-recursion.rs:19:1
|
LL | type X3 = X1;
| ^^^^^^^
|
= note: in case this is a recursive type alias, consider using a struct, enum, or union instead
error: aborting due to 3 previous errors
For more information about this error, try `rustc --explain E0275`.
@@ -0,0 +1,30 @@
error[E0391]: cycle detected when expanding type alias `X1`
--> $DIR/infinite-type-alias-mutual-recursion.rs:12:11
|
LL | type X1 = X2;
| ^^
|
note: ...which requires expanding type alias `X2`...
--> $DIR/infinite-type-alias-mutual-recursion.rs:16:11
|
LL | type X2 = X3;
| ^^
note: ...which requires expanding type alias `X3`...
--> $DIR/infinite-type-alias-mutual-recursion.rs:19:11
|
LL | type X3 = X1;
| ^^
= note: ...which again requires expanding type alias `X1`, completing the cycle
= note: type aliases cannot be recursive
= help: consider using a struct, enum, or union instead to break the cycle
= help: see <https://doc.rust-lang.org/reference/types.html#recursive-types> for more information
note: cycle used when checking that `X1` is well-formed
--> $DIR/infinite-type-alias-mutual-recursion.rs:12:1
|
LL | type X1 = X2;
| ^^^^^^^
= note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
error: aborting due to 1 previous error
For more information about this error, try `rustc --explain E0391`.
@@ -0,0 +1,30 @@
error[E0391]: cycle detected when expanding type alias `X1`
--> $DIR/infinite-type-alias-mutual-recursion.rs:12:11
|
LL | type X1 = X2;
| ^^
|
note: ...which requires expanding type alias `X2`...
--> $DIR/infinite-type-alias-mutual-recursion.rs:16:11
|
LL | type X2 = X3;
| ^^
note: ...which requires expanding type alias `X3`...
--> $DIR/infinite-type-alias-mutual-recursion.rs:19:11
|
LL | type X3 = X1;
| ^^
= note: ...which again requires expanding type alias `X1`, completing the cycle
= note: type aliases cannot be recursive
= help: consider using a struct, enum, or union instead to break the cycle
= help: see <https://doc.rust-lang.org/reference/types.html#recursive-types> for more information
note: cycle used when checking that `X1` is well-formed
--> $DIR/infinite-type-alias-mutual-recursion.rs:12:1
|
LL | type X1 = X2;
| ^^^^^^^
= note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
error: aborting due to 1 previous error
For more information about this error, try `rustc --explain E0391`.
@@ -1,14 +1,23 @@
//@ revisions: feature gated
//@ revisions: feature_old gated_old feature_new gated_new
//@ ignore-parallel-frontend query cycle
#![cfg_attr(feature, feature(lazy_type_alias))]
//@ ignore-compare-mode-next-solver (explicit revisions)
//@ [feature_new] compile-flags: -Znext-solver
//@ [gated_new] compile-flags: -Znext-solver
#![feature(rustc_attrs)]
#![rustc_no_implicit_bounds]
#![cfg_attr(any(feature_old, feature_new), feature(lazy_type_alias))]
#![allow(incomplete_features)]
type X1 = X2;
//[gated]~^ ERROR cycle detected when expanding type alias `X1`
//[feature]~^^ ERROR: overflow normalizing the type alias `X2`
//[gated_old,gated_new]~^ ERROR cycle detected when expanding type alias `X1`
//[feature_old]~^^ ERROR: overflow normalizing the type alias `X2`
//[feature_new]~^^^ ERROR: type mismatch resolving `X3 normalizes-to _`
type X2 = X3;
//[feature]~^ ERROR: overflow normalizing the type alias `X3`
//[feature_old]~^ ERROR: overflow normalizing the type alias `X3`
//[feature_new]~^^ ERROR: type mismatch resolving `X1 normalizes-to _`
type X3 = X1;
//[feature]~^ ERROR: overflow normalizing the type alias `X1`
//[feature_old]~^ ERROR: overflow normalizing the type alias `X1`
//[feature_new]~^^ ERROR: type mismatch resolving `X2 normalizes-to _`
fn main() {}