From c429a72db9515eb3244d6da8c09c15c520aee9db Mon Sep 17 00:00:00 2001 From: nxya Date: Wed, 12 Jul 2023 10:18:30 -0400 Subject: [PATCH 1/7] add links to query documentation for E0391 --- compiler/rustc_error_codes/src/error_codes/E0391.md | 3 +++ compiler/rustc_query_system/messages.ftl | 2 +- tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr | 2 +- tests/ui/associated-consts/defaults-cyclic-fail.stderr | 2 +- .../issue-24949-assoc-const-static-recursion-impl.stderr | 2 +- ...-24949-assoc-const-static-recursion-trait-default.stderr | 2 +- .../issue-24949-assoc-const-static-recursion-trait.stderr | 2 +- .../bugs/cycle-iat-inside-of-adt.stderr | 2 +- .../bugs/cycle-iat-inside-of-where-predicate.stderr | 2 +- .../ui/associated-type-bounds/ambiguous-associated-type2.rs | 3 ++- .../ambiguous-associated-type2.stderr | 2 +- tests/ui/associated-types/issue-20825.stderr | 2 +- .../coherence/coherence-inherited-assoc-ty-cycle-err.stderr | 2 +- tests/ui/const-generics/generic_const_exprs/closures.stderr | 2 +- tests/ui/const-generics/issues/issue-83765.stderr | 2 +- tests/ui/consts/const-size_of-cycle.stderr | 2 +- tests/ui/consts/issue-103790.stderr | 4 ++-- tests/ui/consts/issue-36163.stderr | 2 +- tests/ui/consts/issue-44415.stderr | 2 +- tests/ui/consts/recursive-zst-static.default.stderr | 2 +- tests/ui/consts/recursive-zst-static.unleash.stderr | 2 +- tests/ui/consts/write-to-static-mut-in-static.stderr | 2 +- tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr | 2 +- tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr | 2 +- tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr | 2 +- tests/ui/cycle-trait/issue-12511.stderr | 2 +- tests/ui/dyn-star/param-env-region-infer.next.stderr | 2 +- tests/ui/impl-trait/auto-trait-leak.stderr | 4 ++-- tests/ui/infinite/infinite-trait-alias-recursion.stderr | 2 +- .../ui/infinite/infinite-type-alias-mutual-recursion.stderr | 2 +- tests/ui/infinite/infinite-vec-type-recursion.stderr | 2 +- tests/ui/issues/issue-17252.stderr | 2 +- tests/ui/issues/issue-20772.stderr | 2 +- tests/ui/issues/issue-21177.stderr | 2 +- tests/ui/issues/issue-23302-1.stderr | 2 +- tests/ui/issues/issue-23302-2.stderr | 2 +- tests/ui/issues/issue-23302-3.stderr | 2 +- tests/ui/issues/issue-34373.stderr | 2 +- .../ui/recursion/issue-26548-recursion-via-normalize.stderr | 2 +- tests/ui/recursion/recursive-static-definition.stderr | 2 +- tests/ui/resolve/resolve-self-in-impl.stderr | 2 +- tests/ui/sized/recursive-type-2.stderr | 2 +- tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs | 2 +- .../traits/trait-upcasting/cyclic-trait-resolution.stderr | 2 +- .../type-alias-enum-variants/self-in-enum-definition.stderr | 2 +- tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs | 4 ++-- tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr | 4 ++-- tests/ui/type-alias-impl-trait/inference-cycle.stderr | 4 ++-- tests/ui/type-alias-impl-trait/issue-53092-2.stderr | 2 +- tests/ui/type-alias-impl-trait/reveal_local.stderr | 6 +++--- 50 files changed, 60 insertions(+), 56 deletions(-) diff --git a/compiler/rustc_error_codes/src/error_codes/E0391.md b/compiler/rustc_error_codes/src/error_codes/E0391.md index dff50ccaa0b..457fbd002a1 100644 --- a/compiler/rustc_error_codes/src/error_codes/E0391.md +++ b/compiler/rustc_error_codes/src/error_codes/E0391.md @@ -14,3 +14,6 @@ trait SecondTrait : FirstTrait { The previous example contains a circular dependency between two traits: `FirstTrait` depends on `SecondTrait` which itself depends on `FirstTrait`. + +See https://rustc-dev-guide.rust-lang.org/overview.html#queries and +https://rustc-dev-guide.rust-lang.org/query.html for more information. diff --git a/compiler/rustc_query_system/messages.ftl b/compiler/rustc_query_system/messages.ftl index 49b423d1ade..4e7ddeeebcd 100644 --- a/compiler/rustc_query_system/messages.ftl +++ b/compiler/rustc_query_system/messages.ftl @@ -1,4 +1,4 @@ -query_system_cycle = cycle detected when {$stack_bottom} +query_system_cycle = cycle detected when {$stack_bottom}. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. query_system_cycle_recursive_trait_alias = trait aliases cannot be recursive diff --git a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr index 79e1b753112..0db322fbb75 100644 --- a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr +++ b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when expanding type alias `Bar` +error[E0391]: cycle detected when expanding type alias `Bar`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-110629-private-type-cycle-dyn.rs:1:38 | LL | type Bar<'a, 'b> = Box>>; diff --git a/tests/ui/associated-consts/defaults-cyclic-fail.stderr b/tests/ui/associated-consts/defaults-cyclic-fail.stderr index a1483911b29..bb4788b2ba1 100644 --- a/tests/ui/associated-consts/defaults-cyclic-fail.stderr +++ b/tests/ui/associated-consts/defaults-cyclic-fail.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `Tr::A` +error[E0391]: cycle detected when const-evaluating + checking `Tr::A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/defaults-cyclic-fail.rs:5:19 | LL | const A: u8 = Self::B; diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr index be578176151..eaf06ff1449 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when elaborating drops for `::BAR` +error[E0391]: cycle detected when elaborating drops for `::BAR`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:12:22 | LL | const BAR: u32 = IMPL_REF_BAR; diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr index 8347b260b56..2f36e4ee515 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when elaborating drops for `FooDefault::BAR` +error[E0391]: cycle detected when elaborating drops for `FooDefault::BAR`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:8:22 | LL | const BAR: u32 = DEFAULT_REF_BAR; diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr index 3955a3120c4..24fad93bc54 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when elaborating drops for `::BAR` +error[E0391]: cycle detected when elaborating drops for `::BAR`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:12:22 | LL | const BAR: u32 = TRAIT_REF_BAR; diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr index 23269e1afab..7cf243e546c 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing predicates of `Foo` +error[E0391]: cycle detected when computing predicates of `Foo`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-iat-inside-of-adt.rs:7:1 | LL | struct Foo { diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr index aaa9a39ea0f..e5725e5ef1b 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing predicates of `user` +error[E0391]: cycle detected when computing predicates of `user`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-iat-inside-of-where-predicate.rs:8:1 | LL | fn user() where S::P: std::fmt::Debug {} diff --git a/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs b/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs index 48de593342f..7b2e1365a8f 100644 --- a/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs +++ b/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs @@ -5,6 +5,7 @@ trait Bar { type Item; } trait Baz: Foo + Bar {} -//~^ ERROR cycle detected when computing the super traits of `Baz` with associated type name `Item` [E0391] +//~^ ERROR cycle detected when computing the super traits of `Baz` with associated type name `Item`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] + fn main() {} diff --git a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr index 575b00e09b0..f51d9b381e6 100644 --- a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr +++ b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super traits of `Baz` with associated type name `Item` +error[E0391]: cycle detected when computing the super traits of `Baz` with associated type name `Item`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/ambiguous-associated-type2.rs:7:1 | LL | trait Baz: Foo + Bar {} diff --git a/tests/ui/associated-types/issue-20825.stderr b/tests/ui/associated-types/issue-20825.stderr index c4dea68b884..fda07c78892 100644 --- a/tests/ui/associated-types/issue-20825.stderr +++ b/tests/ui/associated-types/issue-20825.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super traits of `Processor` with associated type name `Input` +error[E0391]: cycle detected when computing the super traits of `Processor` with associated type name `Input`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-20825.rs:5:1 | LL | pub trait Processor: Subscriber { diff --git a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr index 7bd50649d6d..662d023b6aa 100644 --- a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr +++ b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr @@ -8,7 +8,7 @@ LL | #![feature(specialization)] = help: consider using `min_specialization` instead, which is more stable and complete = note: `#[warn(incomplete_features)]` on by default -error[E0391]: cycle detected when building specialization graph of trait `Trait` +error[E0391]: cycle detected when building specialization graph of trait `Trait`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/coherence-inherited-assoc-ty-cycle-err.rs:9:1 | LL | trait Trait { type Assoc; } diff --git a/tests/ui/const-generics/generic_const_exprs/closures.stderr b/tests/ui/const-generics/generic_const_exprs/closures.stderr index a7d891d7790..bac2ef58e91 100644 --- a/tests/ui/const-generics/generic_const_exprs/closures.stderr +++ b/tests/ui/const-generics/generic_const_exprs/closures.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when building an abstract representation for `test::{constant#0}` +error[E0391]: cycle detected when building an abstract representation for `test::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/closures.rs:3:35 | LL | fn test() -> [u8; N + (|| 42)()] {} diff --git a/tests/ui/const-generics/issues/issue-83765.stderr b/tests/ui/const-generics/issues/issue-83765.stderr index d7b2b006c2a..c28a55ec9ae 100644 --- a/tests/ui/const-generics/issues/issue-83765.stderr +++ b/tests/ui/const-generics/issues/issue-83765.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when resolving instance `::DIM, DIM> as TensorDimension>::DIM` +error[E0391]: cycle detected when resolving instance `::DIM, DIM> as TensorDimension>::DIM`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-83765.rs:5:5 | LL | const DIM: usize; diff --git a/tests/ui/consts/const-size_of-cycle.stderr b/tests/ui/consts/const-size_of-cycle.stderr index 17088d9995f..28448223a2a 100644 --- a/tests/ui/consts/const-size_of-cycle.stderr +++ b/tests/ui/consts/const-size_of-cycle.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when evaluating type-level constant +error[E0391]: cycle detected when evaluating type-level constant. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/const-size_of-cycle.rs:4:17 | LL | bytes: [u8; std::mem::size_of::()] diff --git a/tests/ui/consts/issue-103790.stderr b/tests/ui/consts/issue-103790.stderr index 34d8ee281cf..7eae2555ca1 100644 --- a/tests/ui/consts/issue-103790.stderr +++ b/tests/ui/consts/issue-103790.stderr @@ -22,7 +22,7 @@ help: add missing generic argument LL | struct S = { S }>; | +++ -error[E0391]: cycle detected when computing type of `S::S` +error[E0391]: cycle detected when computing type of `S::S`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-103790.rs:4:32 | LL | struct S; @@ -35,7 +35,7 @@ note: cycle used when computing type of `S` LL | struct S; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error[E0391]: cycle detected when computing type of `S` +error[E0391]: cycle detected when computing type of `S`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-103790.rs:4:1 | LL | struct S; diff --git a/tests/ui/consts/issue-36163.stderr b/tests/ui/consts/issue-36163.stderr index 7137c053847..2188dc0e356 100644 --- a/tests/ui/consts/issue-36163.stderr +++ b/tests/ui/consts/issue-36163.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `Foo::B::{constant#0}` +error[E0391]: cycle detected when const-evaluating + checking `Foo::B::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-36163.rs:4:9 | LL | B = A, diff --git a/tests/ui/consts/issue-44415.stderr b/tests/ui/consts/issue-44415.stderr index ec64b956dfe..02be3e644f8 100644 --- a/tests/ui/consts/issue-44415.stderr +++ b/tests/ui/consts/issue-44415.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when evaluating type-level constant +error[E0391]: cycle detected when evaluating type-level constant. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-44415.rs:6:17 | LL | bytes: [u8; unsafe { intrinsics::size_of::() }], diff --git a/tests/ui/consts/recursive-zst-static.default.stderr b/tests/ui/consts/recursive-zst-static.default.stderr index d68960b0972..e4838e92710 100644 --- a/tests/ui/consts/recursive-zst-static.default.stderr +++ b/tests/ui/consts/recursive-zst-static.default.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO` +error[E0391]: cycle detected when const-evaluating + checking `FOO`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/recursive-zst-static.rs:10:1 | LL | static FOO: () = FOO; diff --git a/tests/ui/consts/recursive-zst-static.unleash.stderr b/tests/ui/consts/recursive-zst-static.unleash.stderr index d68960b0972..e4838e92710 100644 --- a/tests/ui/consts/recursive-zst-static.unleash.stderr +++ b/tests/ui/consts/recursive-zst-static.unleash.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO` +error[E0391]: cycle detected when const-evaluating + checking `FOO`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/recursive-zst-static.rs:10:1 | LL | static FOO: () = FOO; diff --git a/tests/ui/consts/write-to-static-mut-in-static.stderr b/tests/ui/consts/write-to-static-mut-in-static.stderr index 395b2d42f97..8816f952d16 100644 --- a/tests/ui/consts/write-to-static-mut-in-static.stderr +++ b/tests/ui/consts/write-to-static-mut-in-static.stderr @@ -4,7 +4,7 @@ error[E0080]: could not evaluate static initializer LL | pub static mut B: () = unsafe { A = 1; }; | ^^^^^ modifying a static's initial value from another static's initializer -error[E0391]: cycle detected when const-evaluating + checking `C` +error[E0391]: cycle detected when const-evaluating + checking `C`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/write-to-static-mut-in-static.rs:5:1 | LL | pub static mut C: u32 = unsafe { C = 1; 0 }; diff --git a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr index 9d715f49471..cfc434e3a36 100644 --- a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr +++ b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Foo::X` +error[E0391]: cycle detected when computing type of `Foo::X`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-trait-default-type-trait.rs:4:23 | LL | trait Foo> { diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr index e2b2aac05ac..4bb9edf3cb5 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `Chromosome` +error[E0391]: cycle detected when computing the super predicates of `Chromosome`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-trait-supertrait-direct.rs:3:19 | LL | trait Chromosome: Chromosome { diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr index c903e114657..61af1f29db7 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `B` +error[E0391]: cycle detected when computing the super predicates of `B`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-trait-supertrait-indirect.rs:7:10 | LL | trait B: C { diff --git a/tests/ui/cycle-trait/issue-12511.stderr b/tests/ui/cycle-trait/issue-12511.stderr index 558aad10946..7c61156065f 100644 --- a/tests/ui/cycle-trait/issue-12511.stderr +++ b/tests/ui/cycle-trait/issue-12511.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `T1` +error[E0391]: cycle detected when computing the super predicates of `T1`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-12511.rs:1:12 | LL | trait T1 : T2 { diff --git a/tests/ui/dyn-star/param-env-region-infer.next.stderr b/tests/ui/dyn-star/param-env-region-infer.next.stderr index dd724a65908..1222645567c 100644 --- a/tests/ui/dyn-star/param-env-region-infer.next.stderr +++ b/tests/ui/dyn-star/param-env-region-infer.next.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `make_dyn_star::{opaque#0}` +error[E0391]: cycle detected when computing type of `make_dyn_star::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/param-env-region-infer.rs:16:60 | LL | fn make_dyn_star<'a, T: PointerLike + Debug + 'a>(t: T) -> impl PointerLike + Debug + 'a { diff --git a/tests/ui/impl-trait/auto-trait-leak.stderr b/tests/ui/impl-trait/auto-trait-leak.stderr index 92a9763bc9b..53b229c2402 100644 --- a/tests/ui/impl-trait/auto-trait-leak.stderr +++ b/tests/ui/impl-trait/auto-trait-leak.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` +error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/auto-trait-leak.rs:11:16 | LL | fn cycle1() -> impl Clone { @@ -34,7 +34,7 @@ LL | | Rc::new(String::from("foo")) LL | | } | |_^ -error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` +error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/auto-trait-leak.rs:11:16 | LL | fn cycle1() -> impl Clone { diff --git a/tests/ui/infinite/infinite-trait-alias-recursion.stderr b/tests/ui/infinite/infinite-trait-alias-recursion.stderr index 683987b4943..56331e17f62 100644 --- a/tests/ui/infinite/infinite-trait-alias-recursion.stderr +++ b/tests/ui/infinite/infinite-trait-alias-recursion.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `T1` +error[E0391]: cycle detected when computing the super predicates of `T1`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/infinite-trait-alias-recursion.rs:3:12 | LL | trait T1 = T2; diff --git a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr index 7f82b294434..547cbc10aea 100644 --- a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr +++ b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when expanding type alias `X1` +error[E0391]: cycle detected when expanding type alias `X1`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/infinite-type-alias-mutual-recursion.rs:1:11 | LL | type X1 = X2; diff --git a/tests/ui/infinite/infinite-vec-type-recursion.stderr b/tests/ui/infinite/infinite-vec-type-recursion.stderr index 1e487a5b11c..a7411cf73d9 100644 --- a/tests/ui/infinite/infinite-vec-type-recursion.stderr +++ b/tests/ui/infinite/infinite-vec-type-recursion.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when expanding type alias `X` +error[E0391]: cycle detected when expanding type alias `X`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/infinite-vec-type-recursion.rs:1:14 | LL | type X = Vec; diff --git a/tests/ui/issues/issue-17252.stderr b/tests/ui/issues/issue-17252.stderr index aca5242b296..bd357003cc7 100644 --- a/tests/ui/issues/issue-17252.stderr +++ b/tests/ui/issues/issue-17252.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO` +error[E0391]: cycle detected when const-evaluating + checking `FOO`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-17252.rs:1:20 | LL | const FOO: usize = FOO; diff --git a/tests/ui/issues/issue-20772.stderr b/tests/ui/issues/issue-20772.stderr index 416fd8c062f..ab692e64cda 100644 --- a/tests/ui/issues/issue-20772.stderr +++ b/tests/ui/issues/issue-20772.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super traits of `T` with associated type name `Item` +error[E0391]: cycle detected when computing the super traits of `T` with associated type name `Item`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-20772.rs:1:1 | LL | trait T : Iterator diff --git a/tests/ui/issues/issue-21177.stderr b/tests/ui/issues/issue-21177.stderr index 6877a184605..69b26cbb105 100644 --- a/tests/ui/issues/issue-21177.stderr +++ b/tests/ui/issues/issue-21177.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the bounds for type parameter `T` +error[E0391]: cycle detected when computing the bounds for type parameter `T`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-21177.rs:6:21 | LL | fn foo>() { } diff --git a/tests/ui/issues/issue-23302-1.stderr b/tests/ui/issues/issue-23302-1.stderr index 9366050d7ec..f238b1c8a21 100644 --- a/tests/ui/issues/issue-23302-1.stderr +++ b/tests/ui/issues/issue-23302-1.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `X::A::{constant#0}` +error[E0391]: cycle detected when const-evaluating + checking `X::A::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-23302-1.rs:4:9 | LL | A = X::A as isize, diff --git a/tests/ui/issues/issue-23302-2.stderr b/tests/ui/issues/issue-23302-2.stderr index b97ae287a47..454b4ad9aa9 100644 --- a/tests/ui/issues/issue-23302-2.stderr +++ b/tests/ui/issues/issue-23302-2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `Y::A::{constant#0}` +error[E0391]: cycle detected when const-evaluating + checking `Y::A::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-23302-2.rs:4:9 | LL | A = Y::B as isize, diff --git a/tests/ui/issues/issue-23302-3.stderr b/tests/ui/issues/issue-23302-3.stderr index c6cafe575e5..318eb42ef3e 100644 --- a/tests/ui/issues/issue-23302-3.stderr +++ b/tests/ui/issues/issue-23302-3.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `A` +error[E0391]: cycle detected when const-evaluating + checking `A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-23302-3.rs:1:16 | LL | const A: i32 = B; diff --git a/tests/ui/issues/issue-34373.stderr b/tests/ui/issues/issue-34373.stderr index 8be3cfa72fb..b7c358a5f6a 100644 --- a/tests/ui/issues/issue-34373.stderr +++ b/tests/ui/issues/issue-34373.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Foo::T` +error[E0391]: cycle detected when computing type of `Foo::T`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-34373.rs:7:30 | LL | pub struct Foo>>; diff --git a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr index a75097cdbfb..48d146d9cdb 100644 --- a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr +++ b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing layout of `core::option::Option` +error[E0391]: cycle detected when computing layout of `core::option::Option`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. | = note: ...which requires computing layout of `S`... = note: ...which requires computing layout of `core::option::Option<::It>`... diff --git a/tests/ui/recursion/recursive-static-definition.stderr b/tests/ui/recursion/recursive-static-definition.stderr index 1359761457a..e5b9e64bcb1 100644 --- a/tests/ui/recursion/recursive-static-definition.stderr +++ b/tests/ui/recursion/recursive-static-definition.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO` +error[E0391]: cycle detected when const-evaluating + checking `FOO`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/recursive-static-definition.rs:1:1 | LL | pub static FOO: u32 = FOO; diff --git a/tests/ui/resolve/resolve-self-in-impl.stderr b/tests/ui/resolve/resolve-self-in-impl.stderr index 9f9ed68898f..e9b6793713f 100644 --- a/tests/ui/resolve/resolve-self-in-impl.stderr +++ b/tests/ui/resolve/resolve-self-in-impl.stderr @@ -38,7 +38,7 @@ LL | impl (Self, Self) {} | = note: replace `Self` with a different type -error[E0391]: cycle detected when computing trait implemented by `` +error[E0391]: cycle detected when computing trait implemented by ``. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/resolve-self-in-impl.rs:19:1 | LL | impl Tr for S {} diff --git a/tests/ui/sized/recursive-type-2.stderr b/tests/ui/sized/recursive-type-2.stderr index d0e6e9db07e..fc68cac9599 100644 --- a/tests/ui/sized/recursive-type-2.stderr +++ b/tests/ui/sized/recursive-type-2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing layout of `Foo<()>` +error[E0391]: cycle detected when computing layout of `Foo<()>`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. | = note: ...which requires computing layout of `<() as A>::Assoc`... = note: ...which again requires computing layout of `Foo<()>`, completing the cycle diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs index 511e41562b2..8efe17d5d0e 100644 --- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs +++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs @@ -1,5 +1,5 @@ trait A: B + A {} -//~^ ERROR cycle detected when computing the super predicates of `A` [E0391] +//~^ ERROR cycle detected when computing the super predicates of `A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] trait B {} diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr index ca98e183150..e20776dafbe 100644 --- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr +++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `A` +error[E0391]: cycle detected when computing the super predicates of `A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cyclic-trait-resolution.rs:1:14 | LL | trait A: B + A {} diff --git a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr index c943a4918ba..b7b6bab8916 100644 --- a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr +++ b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when simplifying constant for the type system `Alpha::V3::{constant#0}` +error[E0391]: cycle detected when simplifying constant for the type system `Alpha::V3::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/self-in-enum-definition.rs:5:10 | LL | V3 = Self::V1 {} as u8 + 2, diff --git a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs index fd3f9c61420..a1c91329246 100644 --- a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs +++ b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs @@ -5,8 +5,8 @@ mod m { pub type Foo = impl std::fmt::Debug; - //~^ ERROR: cycle detected when computing type of `m::Foo::{opaque#0}` [E0391] - //~| ERROR: cycle detected when computing type of `m::Foo::{opaque#0}` [E0391] + //~^ ERROR: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] + //~| ERROR: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] pub fn foo() -> Foo { 22_u32 diff --git a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr index dd56c59bf5f..6ed5d835095 100644 --- a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr +++ b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/auto-trait-leakage3.rs:7:20 | LL | pub type Foo = impl std::fmt::Debug; @@ -17,7 +17,7 @@ note: cycle used when checking item types in module `m` LL | mod m { | ^^^^^ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/auto-trait-leakage3.rs:7:20 | LL | pub type Foo = impl std::fmt::Debug; diff --git a/tests/ui/type-alias-impl-trait/inference-cycle.stderr b/tests/ui/type-alias-impl-trait/inference-cycle.stderr index 4d5f367476b..07b656a0722 100644 --- a/tests/ui/type-alias-impl-trait/inference-cycle.stderr +++ b/tests/ui/type-alias-impl-trait/inference-cycle.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/inference-cycle.rs:5:20 | LL | pub type Foo = impl std::fmt::Debug; @@ -17,7 +17,7 @@ note: cycle used when checking item types in module `m` LL | mod m { | ^^^^^ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/inference-cycle.rs:5:20 | LL | pub type Foo = impl std::fmt::Debug; diff --git a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr index 2565a28b493..909ceedcc65 100644 --- a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr +++ b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Bug::{opaque#0}` +error[E0391]: cycle detected when computing type of `Bug::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-53092-2.rs:4:18 | LL | type Bug = impl Fn(T) -> U + Copy; diff --git a/tests/ui/type-alias-impl-trait/reveal_local.stderr b/tests/ui/type-alias-impl-trait/reveal_local.stderr index 0c5ef4a6fb4..e4a919db956 100644 --- a/tests/ui/type-alias-impl-trait/reveal_local.stderr +++ b/tests/ui/type-alias-impl-trait/reveal_local.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; @@ -23,7 +23,7 @@ LL | | LL | | fn main() {} | |____________^ -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; @@ -69,7 +69,7 @@ note: required by a bound in `is_send` LL | fn is_send() {} | ^^^^ required by this bound in `is_send` -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; From bef91ee6878e3710c0a31f7570c837131e184e0c Mon Sep 17 00:00:00 2001 From: nxya Date: Wed, 12 Jul 2023 22:59:01 -0400 Subject: [PATCH 2/7] added links as a note --- compiler/rustc_query_system/messages.ftl | 3 ++- compiler/rustc_query_system/src/error.rs | 1 + ...issue-110629-private-type-cycle-dyn.stderr | 7 ++++++- .../defaults-cyclic-fail.stderr | 7 ++++++- ...9-assoc-const-static-recursion-impl.stderr | 7 ++++++- ...onst-static-recursion-trait-default.stderr | 7 ++++++- ...-assoc-const-static-recursion-trait.stderr | 7 ++++++- .../bugs/cycle-iat-inside-of-adt.stderr | 7 ++++++- ...cycle-iat-inside-of-where-predicate.stderr | 7 ++++++- .../ambiguous-associated-type2.rs | 2 +- .../ambiguous-associated-type2.stderr | 7 ++++++- tests/ui/associated-types/issue-20825.stderr | 7 ++++++- ...erence-inherited-assoc-ty-cycle-err.stderr | 7 ++++++- .../generic_const_exprs/closures.stderr | 7 ++++++- .../const-generics/issues/issue-83765.stderr | 7 ++++++- tests/ui/consts/const-size_of-cycle.stderr | 7 ++++++- tests/ui/consts/issue-103790.stderr | 14 +++++++++++-- tests/ui/consts/issue-36163.stderr | 7 ++++++- tests/ui/consts/issue-44415.stderr | 7 ++++++- .../recursive-zst-static.default.stderr | 7 ++++++- .../recursive-zst-static.unleash.stderr | 7 ++++++- .../write-to-static-mut-in-static.stderr | 7 ++++++- .../cycle-trait-default-type-trait.stderr | 7 ++++++- .../cycle-trait-supertrait-direct.stderr | 7 ++++++- .../cycle-trait-supertrait-indirect.stderr | 7 ++++++- tests/ui/cycle-trait/issue-12511.stderr | 7 ++++++- .../param-env-region-infer.next.stderr | 7 ++++++- tests/ui/impl-trait/auto-trait-leak.stderr | 14 +++++++++++-- .../infinite-trait-alias-recursion.stderr | 7 ++++++- ...nfinite-type-alias-mutual-recursion.stderr | 7 ++++++- .../infinite-vec-type-recursion.stderr | 7 ++++++- tests/ui/issues/issue-17252.stderr | 7 ++++++- tests/ui/issues/issue-20772.stderr | 7 ++++++- tests/ui/issues/issue-21177.stderr | 7 ++++++- tests/ui/issues/issue-23302-1.stderr | 7 ++++++- tests/ui/issues/issue-23302-2.stderr | 7 ++++++- tests/ui/issues/issue-23302-3.stderr | 7 ++++++- tests/ui/issues/issue-34373.stderr | 7 ++++++- .../issue-26548-recursion-via-normalize.rs | 1 + ...issue-26548-recursion-via-normalize.stderr | 3 ++- .../recursive-static-definition.stderr | 7 ++++++- tests/ui/resolve/resolve-self-in-impl.stderr | 7 ++++++- tests/ui/sized/recursive-type-2.stderr | 3 ++- .../cyclic-trait-resolution.rs | 2 +- .../cyclic-trait-resolution.stderr | 7 ++++++- .../self-in-enum-definition.stderr | 7 ++++++- .../auto-trait-leakage3.rs | 4 ++-- .../auto-trait-leakage3.stderr | 14 +++++++++++-- .../inference-cycle.stderr | 14 +++++++++++-- .../issue-53092-2.stderr | 7 ++++++- .../type-alias-impl-trait/reveal_local.stderr | 21 ++++++++++++++++--- 51 files changed, 306 insertions(+), 56 deletions(-) diff --git a/compiler/rustc_query_system/messages.ftl b/compiler/rustc_query_system/messages.ftl index 4e7ddeeebcd..d5fed8fe179 100644 --- a/compiler/rustc_query_system/messages.ftl +++ b/compiler/rustc_query_system/messages.ftl @@ -1,4 +1,5 @@ -query_system_cycle = cycle detected when {$stack_bottom}. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. +query_system_cycle = cycle detected when {$stack_bottom} + .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 query_system_cycle_recursive_trait_alias = trait aliases cannot be recursive diff --git a/compiler/rustc_query_system/src/error.rs b/compiler/rustc_query_system/src/error.rs index cf2f04c7486..8ed559f2b72 100644 --- a/compiler/rustc_query_system/src/error.rs +++ b/compiler/rustc_query_system/src/error.rs @@ -46,6 +46,7 @@ pub struct CycleUsage { #[derive(Diagnostic)] #[diag(query_system_cycle, code = "E0391")] pub struct Cycle { + #[note] #[primary_span] pub span: Span, pub stack_bottom: String, diff --git a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr index 0db322fbb75..777b4c46798 100644 --- a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr +++ b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when expanding type alias `Bar`. 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[E0391]: cycle detected when expanding type alias `Bar` --> $DIR/issue-110629-private-type-cycle-dyn.rs:1:38 | LL | type Bar<'a, 'b> = Box>>; | ^^^^^^^^^^^ | +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 + --> $DIR/issue-110629-private-type-cycle-dyn.rs:1:38 + | +LL | type Bar<'a, 'b> = Box>>; + | ^^^^^^^^^^^ = note: ...which immediately requires expanding type alias `Bar` again = note: type aliases cannot be recursive = help: consider using a struct, enum, or union instead to break the cycle diff --git a/tests/ui/associated-consts/defaults-cyclic-fail.stderr b/tests/ui/associated-consts/defaults-cyclic-fail.stderr index bb4788b2ba1..d6a13ae4dbf 100644 --- a/tests/ui/associated-consts/defaults-cyclic-fail.stderr +++ b/tests/ui/associated-consts/defaults-cyclic-fail.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when const-evaluating + checking `Tr::A`. 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[E0391]: cycle detected when const-evaluating + checking `Tr::A` --> $DIR/defaults-cyclic-fail.rs:5:19 | LL | const A: u8 = Self::B; | ^^^^^^^ | +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 + --> $DIR/defaults-cyclic-fail.rs:5:19 + | +LL | const A: u8 = Self::B; + | ^^^^^^^ note: ...which requires const-evaluating + checking `Tr::B`... --> $DIR/defaults-cyclic-fail.rs:8:19 | diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr index eaf06ff1449..40b3bcec243 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when elaborating drops for `::BAR`. 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[E0391]: cycle detected when elaborating drops for `::BAR` --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:12:22 | LL | const BAR: u32 = IMPL_REF_BAR; | ^^^^^^^^^^^^ | +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 + --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:12:22 + | +LL | const BAR: u32 = IMPL_REF_BAR; + | ^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `IMPL_REF_BAR`... --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:7:1 | diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr index 2f36e4ee515..e58d93de59d 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when elaborating drops for `FooDefault::BAR`. 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[E0391]: cycle detected when elaborating drops for `FooDefault::BAR` --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:8:22 | LL | const BAR: u32 = DEFAULT_REF_BAR; | ^^^^^^^^^^^^^^^ | +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 + --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:8:22 + | +LL | const BAR: u32 = DEFAULT_REF_BAR; + | ^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `DEFAULT_REF_BAR`... --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:11:1 | diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr index 24fad93bc54..6a97ea64dde 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when elaborating drops for `::BAR`. 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[E0391]: cycle detected when elaborating drops for `::BAR` --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:12:22 | LL | const BAR: u32 = TRAIT_REF_BAR; | ^^^^^^^^^^^^^ | +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 + --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:12:22 + | +LL | const BAR: u32 = TRAIT_REF_BAR; + | ^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `TRAIT_REF_BAR`... --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:7:1 | diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr index 7cf243e546c..f088ecba4a8 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing predicates of `Foo`. 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[E0391]: cycle detected when computing predicates of `Foo` --> $DIR/cycle-iat-inside-of-adt.rs:7:1 | LL | struct Foo { | ^^^^^^^^^^ | +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 + --> $DIR/cycle-iat-inside-of-adt.rs:7:1 + | +LL | struct Foo { + | ^^^^^^^^^^ note: ...which requires computing predicates of `Foo`... --> $DIR/cycle-iat-inside-of-adt.rs:7:1 | diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr index e5725e5ef1b..cfc16d622e9 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing predicates of `user`. 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[E0391]: cycle detected when computing predicates of `user` --> $DIR/cycle-iat-inside-of-where-predicate.rs:8:1 | LL | fn user() where S::P: std::fmt::Debug {} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/cycle-iat-inside-of-where-predicate.rs:8:1 + | +LL | fn user() where S::P: std::fmt::Debug {} + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires computing predicates of `user`... --> $DIR/cycle-iat-inside-of-where-predicate.rs:8:1 | diff --git a/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs b/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs index 7b2e1365a8f..2b6df6d2a32 100644 --- a/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs +++ b/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs @@ -5,7 +5,7 @@ trait Bar { type Item; } trait Baz: Foo + Bar {} -//~^ ERROR cycle detected when computing the super traits of `Baz` with associated type name `Item`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] +//~^ ERROR cycle detected when computing the super traits of `Baz` with associated type name `Item` [E0391] fn main() {} diff --git a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr index f51d9b381e6..4bf53f46233 100644 --- a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr +++ b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing the super traits of `Baz` with associated type name `Item`. 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[E0391]: cycle detected when computing the super traits of `Baz` with associated type name `Item` --> $DIR/ambiguous-associated-type2.rs:7:1 | LL | trait Baz: Foo + Bar {} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/ambiguous-associated-type2.rs:7:1 + | +LL | trait Baz: Foo + Bar {} + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: ...which immediately requires computing the super traits of `Baz` with associated type name `Item` again note: cycle used when computing the super predicates of `Baz` --> $DIR/ambiguous-associated-type2.rs:7:1 diff --git a/tests/ui/associated-types/issue-20825.stderr b/tests/ui/associated-types/issue-20825.stderr index fda07c78892..068f049cae5 100644 --- a/tests/ui/associated-types/issue-20825.stderr +++ b/tests/ui/associated-types/issue-20825.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing the super traits of `Processor` with associated type name `Input`. 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[E0391]: cycle detected when computing the super traits of `Processor` with associated type name `Input` --> $DIR/issue-20825.rs:5:1 | LL | pub trait Processor: Subscriber { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/issue-20825.rs:5:1 + | +LL | pub trait Processor: Subscriber { + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: ...which immediately requires computing the super traits of `Processor` with associated type name `Input` again note: cycle used when computing the super predicates of `Processor` --> $DIR/issue-20825.rs:5:1 diff --git a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr index 662d023b6aa..91e45b0ccb1 100644 --- a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr +++ b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr @@ -8,12 +8,17 @@ LL | #![feature(specialization)] = help: consider using `min_specialization` instead, which is more stable and complete = note: `#[warn(incomplete_features)]` on by default -error[E0391]: cycle detected when building specialization graph of trait `Trait`. 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[E0391]: cycle detected when building specialization graph of trait `Trait` --> $DIR/coherence-inherited-assoc-ty-cycle-err.rs:9:1 | LL | trait Trait { type Assoc; } | ^^^^^^^^^^^^^^ | +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 + --> $DIR/coherence-inherited-assoc-ty-cycle-err.rs:9:1 + | +LL | trait Trait { type Assoc; } + | ^^^^^^^^^^^^^^ = note: ...which immediately requires building specialization graph of trait `Trait` again note: cycle used when coherence checking all impls of trait `Trait` --> $DIR/coherence-inherited-assoc-ty-cycle-err.rs:9:1 diff --git a/tests/ui/const-generics/generic_const_exprs/closures.stderr b/tests/ui/const-generics/generic_const_exprs/closures.stderr index bac2ef58e91..976cd67937a 100644 --- a/tests/ui/const-generics/generic_const_exprs/closures.stderr +++ b/tests/ui/const-generics/generic_const_exprs/closures.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when building an abstract representation for `test::{constant#0}`. 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[E0391]: cycle detected when building an abstract representation for `test::{constant#0}` --> $DIR/closures.rs:3:35 | LL | fn test() -> [u8; N + (|| 42)()] {} | ^^^^^^^^^^^^^ | +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 + --> $DIR/closures.rs:3:35 + | +LL | fn test() -> [u8; N + (|| 42)()] {} + | ^^^^^^^^^^^^^ note: ...which requires building THIR for `test::{constant#0}`... --> $DIR/closures.rs:3:35 | diff --git a/tests/ui/const-generics/issues/issue-83765.stderr b/tests/ui/const-generics/issues/issue-83765.stderr index c28a55ec9ae..bec7eca089d 100644 --- a/tests/ui/const-generics/issues/issue-83765.stderr +++ b/tests/ui/const-generics/issues/issue-83765.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when resolving instance `::DIM, DIM> as TensorDimension>::DIM`. 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[E0391]: cycle detected when resolving instance `::DIM, DIM> as TensorDimension>::DIM` --> $DIR/issue-83765.rs:5:5 | LL | const DIM: usize; | ^^^^^^^^^^^^^^^^ | +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 + --> $DIR/issue-83765.rs:5:5 + | +LL | const DIM: usize; + | ^^^^^^^^^^^^^^^^ note: ...which requires computing candidate for `::DIM, DIM> as TensorDimension>`... --> $DIR/issue-83765.rs:4:1 | diff --git a/tests/ui/consts/const-size_of-cycle.stderr b/tests/ui/consts/const-size_of-cycle.stderr index 28448223a2a..3a18c769246 100644 --- a/tests/ui/consts/const-size_of-cycle.stderr +++ b/tests/ui/consts/const-size_of-cycle.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when evaluating type-level constant. 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[E0391]: cycle detected when evaluating type-level constant --> $DIR/const-size_of-cycle.rs:4:17 | LL | bytes: [u8; std::mem::size_of::()] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/const-size_of-cycle.rs:4:17 + | +LL | bytes: [u8; std::mem::size_of::()] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `Foo::bytes::{constant#0}`... --> $DIR/const-size_of-cycle.rs:4:17 | diff --git a/tests/ui/consts/issue-103790.stderr b/tests/ui/consts/issue-103790.stderr index 7eae2555ca1..917c8b1173e 100644 --- a/tests/ui/consts/issue-103790.stderr +++ b/tests/ui/consts/issue-103790.stderr @@ -22,12 +22,17 @@ help: add missing generic argument LL | struct S = { S }>; | +++ -error[E0391]: cycle detected when computing type of `S::S`. 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[E0391]: cycle detected when computing type of `S::S` --> $DIR/issue-103790.rs:4:32 | LL | struct S; | ^ | +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 + --> $DIR/issue-103790.rs:4:32 + | +LL | struct S; + | ^ = note: ...which immediately requires computing type of `S::S` again note: cycle used when computing type of `S` --> $DIR/issue-103790.rs:4:1 @@ -35,12 +40,17 @@ note: cycle used when computing type of `S` LL | struct S; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error[E0391]: cycle detected when computing type of `S`. 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[E0391]: cycle detected when computing type of `S` --> $DIR/issue-103790.rs:4:1 | LL | struct S; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/issue-103790.rs:4:1 + | +LL | struct S; + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires computing type of `S::S`... --> $DIR/issue-103790.rs:4:32 | diff --git a/tests/ui/consts/issue-36163.stderr b/tests/ui/consts/issue-36163.stderr index 2188dc0e356..fb2866554ff 100644 --- a/tests/ui/consts/issue-36163.stderr +++ b/tests/ui/consts/issue-36163.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when const-evaluating + checking `Foo::B::{constant#0}`. 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[E0391]: cycle detected when const-evaluating + checking `Foo::B::{constant#0}` --> $DIR/issue-36163.rs:4:9 | LL | B = A, | ^ | +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 + --> $DIR/issue-36163.rs:4:9 + | +LL | B = A, + | ^ note: ...which requires const-evaluating + checking `A`... --> $DIR/issue-36163.rs:1:18 | diff --git a/tests/ui/consts/issue-44415.stderr b/tests/ui/consts/issue-44415.stderr index 02be3e644f8..12284ff2fb2 100644 --- a/tests/ui/consts/issue-44415.stderr +++ b/tests/ui/consts/issue-44415.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when evaluating type-level constant. 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[E0391]: cycle detected when evaluating type-level constant --> $DIR/issue-44415.rs:6:17 | LL | bytes: [u8; unsafe { intrinsics::size_of::() }], | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/issue-44415.rs:6:17 + | +LL | bytes: [u8; unsafe { intrinsics::size_of::() }], + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `Foo::bytes::{constant#0}`... --> $DIR/issue-44415.rs:6:17 | diff --git a/tests/ui/consts/recursive-zst-static.default.stderr b/tests/ui/consts/recursive-zst-static.default.stderr index e4838e92710..7f9d7c1cb8b 100644 --- a/tests/ui/consts/recursive-zst-static.default.stderr +++ b/tests/ui/consts/recursive-zst-static.default.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO`. 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[E0391]: cycle detected when const-evaluating + checking `FOO` --> $DIR/recursive-zst-static.rs:10:1 | LL | static FOO: () = FOO; | ^^^^^^^^^^^^^^ | +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 + --> $DIR/recursive-zst-static.rs:10:1 + | +LL | static FOO: () = FOO; + | ^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `FOO`... --> $DIR/recursive-zst-static.rs:10:18 | diff --git a/tests/ui/consts/recursive-zst-static.unleash.stderr b/tests/ui/consts/recursive-zst-static.unleash.stderr index e4838e92710..7f9d7c1cb8b 100644 --- a/tests/ui/consts/recursive-zst-static.unleash.stderr +++ b/tests/ui/consts/recursive-zst-static.unleash.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO`. 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[E0391]: cycle detected when const-evaluating + checking `FOO` --> $DIR/recursive-zst-static.rs:10:1 | LL | static FOO: () = FOO; | ^^^^^^^^^^^^^^ | +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 + --> $DIR/recursive-zst-static.rs:10:1 + | +LL | static FOO: () = FOO; + | ^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `FOO`... --> $DIR/recursive-zst-static.rs:10:18 | diff --git a/tests/ui/consts/write-to-static-mut-in-static.stderr b/tests/ui/consts/write-to-static-mut-in-static.stderr index 8816f952d16..74c636c357b 100644 --- a/tests/ui/consts/write-to-static-mut-in-static.stderr +++ b/tests/ui/consts/write-to-static-mut-in-static.stderr @@ -4,12 +4,17 @@ error[E0080]: could not evaluate static initializer LL | pub static mut B: () = unsafe { A = 1; }; | ^^^^^ modifying a static's initial value from another static's initializer -error[E0391]: cycle detected when const-evaluating + checking `C`. 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[E0391]: cycle detected when const-evaluating + checking `C` --> $DIR/write-to-static-mut-in-static.rs:5:1 | LL | pub static mut C: u32 = unsafe { C = 1; 0 }; | ^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/write-to-static-mut-in-static.rs:5:1 + | +LL | pub static mut C: u32 = unsafe { C = 1; 0 }; + | ^^^^^^^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `C`... --> $DIR/write-to-static-mut-in-static.rs:5:34 | diff --git a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr index cfc434e3a36..3c1f7198de7 100644 --- a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr +++ b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing type of `Foo::X`. 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[E0391]: cycle detected when computing type of `Foo::X` --> $DIR/cycle-trait-default-type-trait.rs:4:23 | LL | trait Foo> { | ^^^ | +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 + --> $DIR/cycle-trait-default-type-trait.rs:4:23 + | +LL | trait Foo> { + | ^^^ = note: ...which immediately requires computing type of `Foo::X` again note: cycle used when collecting item types in top-level module --> $DIR/cycle-trait-default-type-trait.rs:4:1 diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr index 4bb9edf3cb5..26ae7869524 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing the super predicates of `Chromosome`. 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[E0391]: cycle detected when computing the super predicates of `Chromosome` --> $DIR/cycle-trait-supertrait-direct.rs:3:19 | LL | trait Chromosome: Chromosome { | ^^^^^^^^^^ | +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 + --> $DIR/cycle-trait-supertrait-direct.rs:3:19 + | +LL | trait Chromosome: Chromosome { + | ^^^^^^^^^^ = note: ...which immediately requires computing the super predicates of `Chromosome` again note: cycle used when collecting item types in top-level module --> $DIR/cycle-trait-supertrait-direct.rs:3:1 diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr index 61af1f29db7..ec4f4a6ca53 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing the super predicates of `B`. 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[E0391]: cycle detected when computing the super predicates of `B` --> $DIR/cycle-trait-supertrait-indirect.rs:7:10 | LL | trait B: C { | ^ | +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 + --> $DIR/cycle-trait-supertrait-indirect.rs:7:10 + | +LL | trait B: C { + | ^ note: ...which requires computing the super predicates of `C`... --> $DIR/cycle-trait-supertrait-indirect.rs:11:10 | diff --git a/tests/ui/cycle-trait/issue-12511.stderr b/tests/ui/cycle-trait/issue-12511.stderr index 7c61156065f..1e7152fbb39 100644 --- a/tests/ui/cycle-trait/issue-12511.stderr +++ b/tests/ui/cycle-trait/issue-12511.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing the super predicates of `T1`. 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[E0391]: cycle detected when computing the super predicates of `T1` --> $DIR/issue-12511.rs:1:12 | LL | trait T1 : T2 { | ^^ | +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 + --> $DIR/issue-12511.rs:1:12 + | +LL | trait T1 : T2 { + | ^^ note: ...which requires computing the super predicates of `T2`... --> $DIR/issue-12511.rs:5:12 | diff --git a/tests/ui/dyn-star/param-env-region-infer.next.stderr b/tests/ui/dyn-star/param-env-region-infer.next.stderr index 1222645567c..9ea7677389c 100644 --- a/tests/ui/dyn-star/param-env-region-infer.next.stderr +++ b/tests/ui/dyn-star/param-env-region-infer.next.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing type of `make_dyn_star::{opaque#0}`. 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[E0391]: cycle detected when computing type of `make_dyn_star::{opaque#0}` --> $DIR/param-env-region-infer.rs:16:60 | LL | fn make_dyn_star<'a, T: PointerLike + Debug + 'a>(t: T) -> impl PointerLike + Debug + 'a { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/param-env-region-infer.rs:16:60 + | +LL | fn make_dyn_star<'a, T: PointerLike + Debug + 'a>(t: T) -> impl PointerLike + Debug + 'a { + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `make_dyn_star`... --> $DIR/param-env-region-infer.rs:16:1 | diff --git a/tests/ui/impl-trait/auto-trait-leak.stderr b/tests/ui/impl-trait/auto-trait-leak.stderr index 53b229c2402..9c662053c81 100644 --- a/tests/ui/impl-trait/auto-trait-leak.stderr +++ b/tests/ui/impl-trait/auto-trait-leak.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}`. 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[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` --> $DIR/auto-trait-leak.rs:11:16 | LL | fn cycle1() -> impl Clone { | ^^^^^^^^^^ | +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 + --> $DIR/auto-trait-leak.rs:11:16 + | +LL | fn cycle1() -> impl Clone { + | ^^^^^^^^^^ note: ...which requires type-checking `cycle1`... --> $DIR/auto-trait-leak.rs:14:5 | @@ -34,12 +39,17 @@ LL | | Rc::new(String::from("foo")) LL | | } | |_^ -error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}`. 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[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` --> $DIR/auto-trait-leak.rs:11:16 | LL | fn cycle1() -> impl Clone { | ^^^^^^^^^^ | +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 + --> $DIR/auto-trait-leak.rs:11:16 + | +LL | fn cycle1() -> impl Clone { + | ^^^^^^^^^^ note: ...which requires type-checking `cycle1`... --> $DIR/auto-trait-leak.rs:14:5 | diff --git a/tests/ui/infinite/infinite-trait-alias-recursion.stderr b/tests/ui/infinite/infinite-trait-alias-recursion.stderr index 56331e17f62..36894dc1894 100644 --- a/tests/ui/infinite/infinite-trait-alias-recursion.stderr +++ b/tests/ui/infinite/infinite-trait-alias-recursion.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing the super predicates of `T1`. 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[E0391]: cycle detected when computing the super predicates of `T1` --> $DIR/infinite-trait-alias-recursion.rs:3:12 | LL | trait T1 = T2; | ^^ | +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 + --> $DIR/infinite-trait-alias-recursion.rs:3:12 + | +LL | trait T1 = T2; + | ^^ note: ...which requires computing the super predicates of `T2`... --> $DIR/infinite-trait-alias-recursion.rs:6:12 | diff --git a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr index 547cbc10aea..7a4900e5110 100644 --- a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr +++ b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when expanding type alias `X1`. 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[E0391]: cycle detected when expanding type alias `X1` --> $DIR/infinite-type-alias-mutual-recursion.rs:1:11 | 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 + --> $DIR/infinite-type-alias-mutual-recursion.rs:1:11 + | +LL | type X1 = X2; + | ^^ note: ...which requires expanding type alias `X2`... --> $DIR/infinite-type-alias-mutual-recursion.rs:3:11 | diff --git a/tests/ui/infinite/infinite-vec-type-recursion.stderr b/tests/ui/infinite/infinite-vec-type-recursion.stderr index a7411cf73d9..82a53f13f14 100644 --- a/tests/ui/infinite/infinite-vec-type-recursion.stderr +++ b/tests/ui/infinite/infinite-vec-type-recursion.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when expanding type alias `X`. 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[E0391]: cycle detected when expanding type alias `X` --> $DIR/infinite-vec-type-recursion.rs:1:14 | LL | type X = Vec; | ^ | +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 + --> $DIR/infinite-vec-type-recursion.rs:1:14 + | +LL | type X = Vec; + | ^ = note: ...which immediately requires expanding type alias `X` again = note: type aliases cannot be recursive = help: consider using a struct, enum, or union instead to break the cycle diff --git a/tests/ui/issues/issue-17252.stderr b/tests/ui/issues/issue-17252.stderr index bd357003cc7..eaaa6b6dc62 100644 --- a/tests/ui/issues/issue-17252.stderr +++ b/tests/ui/issues/issue-17252.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO`. 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[E0391]: cycle detected when const-evaluating + checking `FOO` --> $DIR/issue-17252.rs:1:20 | LL | const FOO: usize = FOO; | ^^^ | +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 + --> $DIR/issue-17252.rs:1:20 + | +LL | const FOO: usize = FOO; + | ^^^ = note: ...which immediately requires const-evaluating + checking `FOO` again note: cycle used when const-evaluating + checking `main::{constant#0}` --> $DIR/issue-17252.rs:4:18 diff --git a/tests/ui/issues/issue-20772.stderr b/tests/ui/issues/issue-20772.stderr index ab692e64cda..1d51be58954 100644 --- a/tests/ui/issues/issue-20772.stderr +++ b/tests/ui/issues/issue-20772.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing the super traits of `T` with associated type name `Item`. 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[E0391]: cycle detected when computing the super traits of `T` with associated type name `Item` --> $DIR/issue-20772.rs:1:1 | LL | trait T : Iterator | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/issue-20772.rs:1:1 + | +LL | trait T : Iterator + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: ...which immediately requires computing the super traits of `T` with associated type name `Item` again note: cycle used when computing the super predicates of `T` --> $DIR/issue-20772.rs:1:1 diff --git a/tests/ui/issues/issue-21177.stderr b/tests/ui/issues/issue-21177.stderr index 69b26cbb105..b3e550b36d8 100644 --- a/tests/ui/issues/issue-21177.stderr +++ b/tests/ui/issues/issue-21177.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing the bounds for type parameter `T`. 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[E0391]: cycle detected when computing the bounds for type parameter `T` --> $DIR/issue-21177.rs:6:21 | LL | fn foo>() { } | ^^^^ | +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 + --> $DIR/issue-21177.rs:6:21 + | +LL | fn foo>() { } + | ^^^^ = note: ...which immediately requires computing the bounds for type parameter `T` again note: cycle used when computing explicit predicates of `foo` --> $DIR/issue-21177.rs:6:21 diff --git a/tests/ui/issues/issue-23302-1.stderr b/tests/ui/issues/issue-23302-1.stderr index f238b1c8a21..86773f13511 100644 --- a/tests/ui/issues/issue-23302-1.stderr +++ b/tests/ui/issues/issue-23302-1.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when const-evaluating + checking `X::A::{constant#0}`. 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[E0391]: cycle detected when const-evaluating + checking `X::A::{constant#0}` --> $DIR/issue-23302-1.rs:4:9 | LL | A = X::A as isize, | ^^^^^^^^^^^^^ | +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 + --> $DIR/issue-23302-1.rs:4:9 + | +LL | A = X::A as isize, + | ^^^^^^^^^^^^^ = note: ...which immediately requires const-evaluating + checking `X::A::{constant#0}` again note: cycle used when simplifying constant for the type system `X::A::{constant#0}` --> $DIR/issue-23302-1.rs:4:9 diff --git a/tests/ui/issues/issue-23302-2.stderr b/tests/ui/issues/issue-23302-2.stderr index 454b4ad9aa9..67d07219d16 100644 --- a/tests/ui/issues/issue-23302-2.stderr +++ b/tests/ui/issues/issue-23302-2.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when const-evaluating + checking `Y::A::{constant#0}`. 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[E0391]: cycle detected when const-evaluating + checking `Y::A::{constant#0}` --> $DIR/issue-23302-2.rs:4:9 | LL | A = Y::B as isize, | ^^^^^^^^^^^^^ | +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 + --> $DIR/issue-23302-2.rs:4:9 + | +LL | A = Y::B as isize, + | ^^^^^^^^^^^^^ = note: ...which immediately requires const-evaluating + checking `Y::A::{constant#0}` again note: cycle used when simplifying constant for the type system `Y::A::{constant#0}` --> $DIR/issue-23302-2.rs:4:9 diff --git a/tests/ui/issues/issue-23302-3.stderr b/tests/ui/issues/issue-23302-3.stderr index 318eb42ef3e..0cbeee1d079 100644 --- a/tests/ui/issues/issue-23302-3.stderr +++ b/tests/ui/issues/issue-23302-3.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when const-evaluating + checking `A`. 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[E0391]: cycle detected when const-evaluating + checking `A` --> $DIR/issue-23302-3.rs:1:16 | LL | const A: i32 = B; | ^ | +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 + --> $DIR/issue-23302-3.rs:1:16 + | +LL | const A: i32 = B; + | ^ note: ...which requires const-evaluating + checking `B`... --> $DIR/issue-23302-3.rs:3:16 | diff --git a/tests/ui/issues/issue-34373.stderr b/tests/ui/issues/issue-34373.stderr index b7c358a5f6a..e2c0c9182bb 100644 --- a/tests/ui/issues/issue-34373.stderr +++ b/tests/ui/issues/issue-34373.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing type of `Foo::T`. 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[E0391]: cycle detected when computing type of `Foo::T` --> $DIR/issue-34373.rs:7:30 | LL | pub struct Foo>>; | ^^^^^^^^^^ | +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 + --> $DIR/issue-34373.rs:7:30 + | +LL | pub struct Foo>>; + | ^^^^^^^^^^ note: ...which requires expanding type alias `DefaultFoo`... --> $DIR/issue-34373.rs:8:19 | diff --git a/tests/ui/recursion/issue-26548-recursion-via-normalize.rs b/tests/ui/recursion/issue-26548-recursion-via-normalize.rs index 91958dffcf4..6c7fc4beb54 100644 --- a/tests/ui/recursion/issue-26548-recursion-via-normalize.rs +++ b/tests/ui/recursion/issue-26548-recursion-via-normalize.rs @@ -1,4 +1,5 @@ //~ ERROR cycle detected when computing layout of `core::option::Option` +//~| 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 //~| NOTE ...which requires computing layout of `S`... //~| NOTE ...which requires computing layout of `core::option::Option<::It>`... //~| NOTE ...which again requires computing layout of `core::option::Option`, completing the cycle diff --git a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr index 48d146d9cdb..cdd4937e724 100644 --- a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr +++ b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr @@ -1,5 +1,6 @@ -error[E0391]: cycle detected when computing layout of `core::option::Option`. 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[E0391]: cycle detected when computing layout of `core::option::Option` | + = 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 = note: ...which requires computing layout of `S`... = note: ...which requires computing layout of `core::option::Option<::It>`... = note: ...which again requires computing layout of `core::option::Option`, completing the cycle diff --git a/tests/ui/recursion/recursive-static-definition.stderr b/tests/ui/recursion/recursive-static-definition.stderr index e5b9e64bcb1..85ca99bef45 100644 --- a/tests/ui/recursion/recursive-static-definition.stderr +++ b/tests/ui/recursion/recursive-static-definition.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO`. 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[E0391]: cycle detected when const-evaluating + checking `FOO` --> $DIR/recursive-static-definition.rs:1:1 | LL | pub static FOO: u32 = FOO; | ^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/recursive-static-definition.rs:1:1 + | +LL | pub static FOO: u32 = FOO; + | ^^^^^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `FOO`... --> $DIR/recursive-static-definition.rs:1:23 | diff --git a/tests/ui/resolve/resolve-self-in-impl.stderr b/tests/ui/resolve/resolve-self-in-impl.stderr index e9b6793713f..f9dc44d5b9a 100644 --- a/tests/ui/resolve/resolve-self-in-impl.stderr +++ b/tests/ui/resolve/resolve-self-in-impl.stderr @@ -38,12 +38,17 @@ LL | impl (Self, Self) {} | = note: replace `Self` with a different type -error[E0391]: cycle detected when computing trait implemented by ``. 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[E0391]: cycle detected when computing trait implemented by `` --> $DIR/resolve-self-in-impl.rs:19:1 | LL | impl Tr for S {} | ^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/resolve-self-in-impl.rs:19:1 + | +LL | impl Tr for S {} + | ^^^^^^^^^^^^^^^^^^^^^^ = note: ...which immediately requires computing trait implemented by `` again note: cycle used when collecting item types in top-level module --> $DIR/resolve-self-in-impl.rs:1:1 diff --git a/tests/ui/sized/recursive-type-2.stderr b/tests/ui/sized/recursive-type-2.stderr index fc68cac9599..574c0e0021f 100644 --- a/tests/ui/sized/recursive-type-2.stderr +++ b/tests/ui/sized/recursive-type-2.stderr @@ -1,5 +1,6 @@ -error[E0391]: cycle detected when computing layout of `Foo<()>`. 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[E0391]: cycle detected when computing layout of `Foo<()>` | + = 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 = note: ...which requires computing layout of `<() as A>::Assoc`... = note: ...which again requires computing layout of `Foo<()>`, completing the cycle note: cycle used when elaborating drops for `main` diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs index 8efe17d5d0e..511e41562b2 100644 --- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs +++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs @@ -1,5 +1,5 @@ trait A: B + A {} -//~^ ERROR cycle detected when computing the super predicates of `A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] +//~^ ERROR cycle detected when computing the super predicates of `A` [E0391] trait B {} diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr index e20776dafbe..af1fa1594ce 100644 --- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr +++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing the super predicates of `A`. 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[E0391]: cycle detected when computing the super predicates of `A` --> $DIR/cyclic-trait-resolution.rs:1:14 | LL | trait A: B + A {} | ^ | +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 + --> $DIR/cyclic-trait-resolution.rs:1:14 + | +LL | trait A: B + A {} + | ^ = note: ...which immediately requires computing the super predicates of `A` again note: cycle used when collecting item types in top-level module --> $DIR/cyclic-trait-resolution.rs:1:1 diff --git a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr index b7b6bab8916..be76d0b2621 100644 --- a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr +++ b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when simplifying constant for the type system `Alpha::V3::{constant#0}`. 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[E0391]: cycle detected when simplifying constant for the type system `Alpha::V3::{constant#0}` --> $DIR/self-in-enum-definition.rs:5:10 | LL | V3 = Self::V1 {} as u8 + 2, | ^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/self-in-enum-definition.rs:5:10 + | +LL | V3 = Self::V1 {} as u8 + 2, + | ^^^^^^^^^^^^^^^^^^^^^ note: ...which requires simplifying constant for the type system `Alpha::V3::{constant#0}`... --> $DIR/self-in-enum-definition.rs:5:10 | diff --git a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs index a1c91329246..fd3f9c61420 100644 --- a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs +++ b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs @@ -5,8 +5,8 @@ mod m { pub type Foo = impl std::fmt::Debug; - //~^ ERROR: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] - //~| ERROR: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] + //~^ ERROR: cycle detected when computing type of `m::Foo::{opaque#0}` [E0391] + //~| ERROR: cycle detected when computing type of `m::Foo::{opaque#0}` [E0391] pub fn foo() -> Foo { 22_u32 diff --git a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr index 6ed5d835095..fb414bca91e 100644 --- a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr +++ b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/auto-trait-leakage3.rs:7:20 | LL | pub type Foo = impl std::fmt::Debug; | ^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/auto-trait-leakage3.rs:7:20 + | +LL | pub type Foo = impl std::fmt::Debug; + | ^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `m::bar`... --> $DIR/auto-trait-leakage3.rs:16:9 | @@ -17,12 +22,17 @@ note: cycle used when checking item types in module `m` LL | mod m { | ^^^^^ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/auto-trait-leakage3.rs:7:20 | LL | pub type Foo = impl std::fmt::Debug; | ^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/auto-trait-leakage3.rs:7:20 + | +LL | pub type Foo = impl std::fmt::Debug; + | ^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `m::bar`... --> $DIR/auto-trait-leakage3.rs:15:5 | diff --git a/tests/ui/type-alias-impl-trait/inference-cycle.stderr b/tests/ui/type-alias-impl-trait/inference-cycle.stderr index 07b656a0722..6a14ec8f099 100644 --- a/tests/ui/type-alias-impl-trait/inference-cycle.stderr +++ b/tests/ui/type-alias-impl-trait/inference-cycle.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/inference-cycle.rs:5:20 | LL | pub type Foo = impl std::fmt::Debug; | ^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/inference-cycle.rs:5:20 + | +LL | pub type Foo = impl std::fmt::Debug; + | ^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `m::bar`... --> $DIR/inference-cycle.rs:16:9 | @@ -17,12 +22,17 @@ note: cycle used when checking item types in module `m` LL | mod m { | ^^^^^ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/inference-cycle.rs:5:20 | LL | pub type Foo = impl std::fmt::Debug; | ^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/inference-cycle.rs:5:20 + | +LL | pub type Foo = impl std::fmt::Debug; + | ^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `m::bar`... --> $DIR/inference-cycle.rs:15:5 | diff --git a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr index 909ceedcc65..e23b9f3845c 100644 --- a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr +++ b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing type of `Bug::{opaque#0}`. 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[E0391]: cycle detected when computing type of `Bug::{opaque#0}` --> $DIR/issue-53092-2.rs:4:18 | LL | type Bug = impl Fn(T) -> U + Copy; | ^^^^^^^^^^^^^^^^^^^^^^ | +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 + --> $DIR/issue-53092-2.rs:4:18 + | +LL | type Bug = impl Fn(T) -> U + Copy; + | ^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `CONST_BUG`... --> $DIR/issue-53092-2.rs:6:1 | diff --git a/tests/ui/type-alias-impl-trait/reveal_local.stderr b/tests/ui/type-alias-impl-trait/reveal_local.stderr index e4a919db956..6c5fe8cf32f 100644 --- a/tests/ui/type-alias-impl-trait/reveal_local.stderr +++ b/tests/ui/type-alias-impl-trait/reveal_local.stderr @@ -1,9 +1,14 @@ -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `Foo::{opaque#0}` --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; | ^^^^^^^^^^ | +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 + --> $DIR/reveal_local.rs:5:12 + | +LL | type Foo = impl Debug; + | ^^^^^^^^^^ note: ...which requires type-checking `not_good`... --> $DIR/reveal_local.rs:15:5 | @@ -23,12 +28,17 @@ LL | | LL | | fn main() {} | |____________^ -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `Foo::{opaque#0}` --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; | ^^^^^^^^^^ | +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 + --> $DIR/reveal_local.rs:5:12 + | +LL | type Foo = impl Debug; + | ^^^^^^^^^^ note: ...which requires type-checking `not_good`... --> $DIR/reveal_local.rs:12:1 | @@ -69,12 +79,17 @@ note: required by a bound in `is_send` LL | fn is_send() {} | ^^^^ required by this bound in `is_send` -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `Foo::{opaque#0}` --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; | ^^^^^^^^^^ | +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 + --> $DIR/reveal_local.rs:5:12 + | +LL | type Foo = impl Debug; + | ^^^^^^^^^^ note: ...which requires type-checking `not_gooder`... --> $DIR/reveal_local.rs:19:1 | From 5f68a5d20473eecf06c2039e7e6dedd10e17990c Mon Sep 17 00:00:00 2001 From: nxya Date: Thu, 13 Jul 2023 11:41:44 -0400 Subject: [PATCH 3/7] fix miri test with links to query documentation --- src/tools/miri/tests/fail/layout_cycle.stderr | 1 + 1 file changed, 1 insertion(+) diff --git a/src/tools/miri/tests/fail/layout_cycle.stderr b/src/tools/miri/tests/fail/layout_cycle.stderr index 62b7d5fb77d..011b1adab95 100644 --- a/src/tools/miri/tests/fail/layout_cycle.stderr +++ b/src/tools/miri/tests/fail/layout_cycle.stderr @@ -1,5 +1,6 @@ error[E0391]: cycle detected when computing layout of `S>` | + = 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 = note: ...which requires computing layout of ` as Tr>::I`... = note: ...which again requires computing layout of `S>`, completing the cycle From f92a9f6808292558e60fc0d86bbaabf6ebb670cc Mon Sep 17 00:00:00 2001 From: nxya Date: Wed, 12 Jul 2023 10:18:30 -0400 Subject: [PATCH 4/7] add links to query documentation for E0391 --- tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr | 2 +- tests/ui/associated-consts/defaults-cyclic-fail.stderr | 2 +- .../issue-24949-assoc-const-static-recursion-impl.stderr | 2 +- ...-24949-assoc-const-static-recursion-trait-default.stderr | 2 +- .../issue-24949-assoc-const-static-recursion-trait.stderr | 2 +- .../bugs/cycle-iat-inside-of-adt.stderr | 2 +- .../bugs/cycle-iat-inside-of-where-predicate.stderr | 2 +- .../ui/associated-type-bounds/ambiguous-associated-type2.rs | 3 ++- .../ambiguous-associated-type2.stderr | 2 +- tests/ui/associated-types/issue-20825.stderr | 2 +- .../coherence/coherence-inherited-assoc-ty-cycle-err.stderr | 2 +- tests/ui/const-generics/generic_const_exprs/closures.stderr | 2 +- tests/ui/const-generics/issues/issue-83765.stderr | 2 +- tests/ui/consts/const-size_of-cycle.stderr | 2 +- tests/ui/consts/issue-103790.stderr | 4 ++-- tests/ui/consts/issue-36163.stderr | 2 +- tests/ui/consts/issue-44415.stderr | 2 +- tests/ui/consts/recursive-zst-static.default.stderr | 2 +- tests/ui/consts/recursive-zst-static.unleash.stderr | 2 +- tests/ui/consts/write-to-static-mut-in-static.stderr | 2 +- tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr | 2 +- tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr | 2 +- tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr | 2 +- tests/ui/cycle-trait/issue-12511.stderr | 2 +- tests/ui/dyn-star/param-env-region-infer.next.stderr | 2 +- tests/ui/impl-trait/auto-trait-leak.stderr | 4 ++-- tests/ui/infinite/infinite-trait-alias-recursion.stderr | 2 +- .../ui/infinite/infinite-type-alias-mutual-recursion.stderr | 2 +- tests/ui/infinite/infinite-vec-type-recursion.stderr | 2 +- tests/ui/issues/issue-17252.stderr | 2 +- tests/ui/issues/issue-20772.stderr | 2 +- tests/ui/issues/issue-21177.stderr | 2 +- tests/ui/issues/issue-23302-1.stderr | 2 +- tests/ui/issues/issue-23302-2.stderr | 2 +- tests/ui/issues/issue-23302-3.stderr | 2 +- tests/ui/issues/issue-34373.stderr | 2 +- .../ui/recursion/issue-26548-recursion-via-normalize.stderr | 2 +- tests/ui/recursion/recursive-static-definition.stderr | 2 +- tests/ui/resolve/resolve-self-in-impl.stderr | 2 +- tests/ui/sized/recursive-type-2.stderr | 2 +- tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs | 2 +- .../traits/trait-upcasting/cyclic-trait-resolution.stderr | 2 +- .../type-alias-enum-variants/self-in-enum-definition.stderr | 2 +- tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs | 4 ++-- tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr | 4 ++-- tests/ui/type-alias-impl-trait/inference-cycle.stderr | 4 ++-- tests/ui/type-alias-impl-trait/issue-53092-2.stderr | 2 +- tests/ui/type-alias-impl-trait/reveal_local.stderr | 6 +++--- 48 files changed, 56 insertions(+), 55 deletions(-) diff --git a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr index 777b4c46798..cc2fbfd5420 100644 --- a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr +++ b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when expanding type alias `Bar` +error[E0391]: cycle detected when expanding type alias `Bar`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-110629-private-type-cycle-dyn.rs:1:38 | LL | type Bar<'a, 'b> = Box>>; diff --git a/tests/ui/associated-consts/defaults-cyclic-fail.stderr b/tests/ui/associated-consts/defaults-cyclic-fail.stderr index d6a13ae4dbf..10a6417f658 100644 --- a/tests/ui/associated-consts/defaults-cyclic-fail.stderr +++ b/tests/ui/associated-consts/defaults-cyclic-fail.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `Tr::A` +error[E0391]: cycle detected when const-evaluating + checking `Tr::A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/defaults-cyclic-fail.rs:5:19 | LL | const A: u8 = Self::B; diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr index 40b3bcec243..5c15bc262cc 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when elaborating drops for `::BAR` +error[E0391]: cycle detected when elaborating drops for `::BAR`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:12:22 | LL | const BAR: u32 = IMPL_REF_BAR; diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr index e58d93de59d..ab85dc78fc1 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when elaborating drops for `FooDefault::BAR` +error[E0391]: cycle detected when elaborating drops for `FooDefault::BAR`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:8:22 | LL | const BAR: u32 = DEFAULT_REF_BAR; diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr index 6a97ea64dde..48c1c32a1e2 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when elaborating drops for `::BAR` +error[E0391]: cycle detected when elaborating drops for `::BAR`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:12:22 | LL | const BAR: u32 = TRAIT_REF_BAR; diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr index f088ecba4a8..6e3864ebf28 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing predicates of `Foo` +error[E0391]: cycle detected when computing predicates of `Foo`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-iat-inside-of-adt.rs:7:1 | LL | struct Foo { diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr index cfc16d622e9..64616c20661 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing predicates of `user` +error[E0391]: cycle detected when computing predicates of `user`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-iat-inside-of-where-predicate.rs:8:1 | LL | fn user() where S::P: std::fmt::Debug {} diff --git a/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs b/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs index 2b6df6d2a32..b7a60a2cba4 100644 --- a/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs +++ b/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs @@ -5,7 +5,8 @@ trait Bar { type Item; } trait Baz: Foo + Bar {} -//~^ ERROR cycle detected when computing the super traits of `Baz` with associated type name `Item` [E0391] +//~^ ERROR cycle detected when computing the super traits of `Baz` with associated type name `Item`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] + fn main() {} diff --git a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr index 4bf53f46233..6a55afc4027 100644 --- a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr +++ b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super traits of `Baz` with associated type name `Item` +error[E0391]: cycle detected when computing the super traits of `Baz` with associated type name `Item`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/ambiguous-associated-type2.rs:7:1 | LL | trait Baz: Foo + Bar {} diff --git a/tests/ui/associated-types/issue-20825.stderr b/tests/ui/associated-types/issue-20825.stderr index 068f049cae5..2f2d9c20dd4 100644 --- a/tests/ui/associated-types/issue-20825.stderr +++ b/tests/ui/associated-types/issue-20825.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super traits of `Processor` with associated type name `Input` +error[E0391]: cycle detected when computing the super traits of `Processor` with associated type name `Input`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-20825.rs:5:1 | LL | pub trait Processor: Subscriber { diff --git a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr index 91e45b0ccb1..c9ee2340bab 100644 --- a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr +++ b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr @@ -8,7 +8,7 @@ LL | #![feature(specialization)] = help: consider using `min_specialization` instead, which is more stable and complete = note: `#[warn(incomplete_features)]` on by default -error[E0391]: cycle detected when building specialization graph of trait `Trait` +error[E0391]: cycle detected when building specialization graph of trait `Trait`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/coherence-inherited-assoc-ty-cycle-err.rs:9:1 | LL | trait Trait { type Assoc; } diff --git a/tests/ui/const-generics/generic_const_exprs/closures.stderr b/tests/ui/const-generics/generic_const_exprs/closures.stderr index 976cd67937a..8c158555f50 100644 --- a/tests/ui/const-generics/generic_const_exprs/closures.stderr +++ b/tests/ui/const-generics/generic_const_exprs/closures.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when building an abstract representation for `test::{constant#0}` +error[E0391]: cycle detected when building an abstract representation for `test::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/closures.rs:3:35 | LL | fn test() -> [u8; N + (|| 42)()] {} diff --git a/tests/ui/const-generics/issues/issue-83765.stderr b/tests/ui/const-generics/issues/issue-83765.stderr index bec7eca089d..656e5ca02d1 100644 --- a/tests/ui/const-generics/issues/issue-83765.stderr +++ b/tests/ui/const-generics/issues/issue-83765.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when resolving instance `::DIM, DIM> as TensorDimension>::DIM` +error[E0391]: cycle detected when resolving instance `::DIM, DIM> as TensorDimension>::DIM`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-83765.rs:5:5 | LL | const DIM: usize; diff --git a/tests/ui/consts/const-size_of-cycle.stderr b/tests/ui/consts/const-size_of-cycle.stderr index 3a18c769246..8211bb53670 100644 --- a/tests/ui/consts/const-size_of-cycle.stderr +++ b/tests/ui/consts/const-size_of-cycle.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when evaluating type-level constant +error[E0391]: cycle detected when evaluating type-level constant. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/const-size_of-cycle.rs:4:17 | LL | bytes: [u8; std::mem::size_of::()] diff --git a/tests/ui/consts/issue-103790.stderr b/tests/ui/consts/issue-103790.stderr index 917c8b1173e..feb6138ced8 100644 --- a/tests/ui/consts/issue-103790.stderr +++ b/tests/ui/consts/issue-103790.stderr @@ -22,7 +22,7 @@ help: add missing generic argument LL | struct S = { S }>; | +++ -error[E0391]: cycle detected when computing type of `S::S` +error[E0391]: cycle detected when computing type of `S::S`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-103790.rs:4:32 | LL | struct S; @@ -40,7 +40,7 @@ note: cycle used when computing type of `S` LL | struct S; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error[E0391]: cycle detected when computing type of `S` +error[E0391]: cycle detected when computing type of `S`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-103790.rs:4:1 | LL | struct S; diff --git a/tests/ui/consts/issue-36163.stderr b/tests/ui/consts/issue-36163.stderr index fb2866554ff..de506b4c614 100644 --- a/tests/ui/consts/issue-36163.stderr +++ b/tests/ui/consts/issue-36163.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `Foo::B::{constant#0}` +error[E0391]: cycle detected when const-evaluating + checking `Foo::B::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-36163.rs:4:9 | LL | B = A, diff --git a/tests/ui/consts/issue-44415.stderr b/tests/ui/consts/issue-44415.stderr index 12284ff2fb2..d258f48f4ee 100644 --- a/tests/ui/consts/issue-44415.stderr +++ b/tests/ui/consts/issue-44415.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when evaluating type-level constant +error[E0391]: cycle detected when evaluating type-level constant. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-44415.rs:6:17 | LL | bytes: [u8; unsafe { intrinsics::size_of::() }], diff --git a/tests/ui/consts/recursive-zst-static.default.stderr b/tests/ui/consts/recursive-zst-static.default.stderr index 7f9d7c1cb8b..f57ae40dac3 100644 --- a/tests/ui/consts/recursive-zst-static.default.stderr +++ b/tests/ui/consts/recursive-zst-static.default.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO` +error[E0391]: cycle detected when const-evaluating + checking `FOO`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/recursive-zst-static.rs:10:1 | LL | static FOO: () = FOO; diff --git a/tests/ui/consts/recursive-zst-static.unleash.stderr b/tests/ui/consts/recursive-zst-static.unleash.stderr index 7f9d7c1cb8b..f57ae40dac3 100644 --- a/tests/ui/consts/recursive-zst-static.unleash.stderr +++ b/tests/ui/consts/recursive-zst-static.unleash.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO` +error[E0391]: cycle detected when const-evaluating + checking `FOO`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/recursive-zst-static.rs:10:1 | LL | static FOO: () = FOO; diff --git a/tests/ui/consts/write-to-static-mut-in-static.stderr b/tests/ui/consts/write-to-static-mut-in-static.stderr index 74c636c357b..a88d09f54b3 100644 --- a/tests/ui/consts/write-to-static-mut-in-static.stderr +++ b/tests/ui/consts/write-to-static-mut-in-static.stderr @@ -4,7 +4,7 @@ error[E0080]: could not evaluate static initializer LL | pub static mut B: () = unsafe { A = 1; }; | ^^^^^ modifying a static's initial value from another static's initializer -error[E0391]: cycle detected when const-evaluating + checking `C` +error[E0391]: cycle detected when const-evaluating + checking `C`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/write-to-static-mut-in-static.rs:5:1 | LL | pub static mut C: u32 = unsafe { C = 1; 0 }; diff --git a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr index 3c1f7198de7..39d4a96da29 100644 --- a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr +++ b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Foo::X` +error[E0391]: cycle detected when computing type of `Foo::X`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-trait-default-type-trait.rs:4:23 | LL | trait Foo> { diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr index 26ae7869524..69c1b47ab96 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `Chromosome` +error[E0391]: cycle detected when computing the super predicates of `Chromosome`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-trait-supertrait-direct.rs:3:19 | LL | trait Chromosome: Chromosome { diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr index ec4f4a6ca53..42ecd262545 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `B` +error[E0391]: cycle detected when computing the super predicates of `B`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cycle-trait-supertrait-indirect.rs:7:10 | LL | trait B: C { diff --git a/tests/ui/cycle-trait/issue-12511.stderr b/tests/ui/cycle-trait/issue-12511.stderr index 1e7152fbb39..000726d5585 100644 --- a/tests/ui/cycle-trait/issue-12511.stderr +++ b/tests/ui/cycle-trait/issue-12511.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `T1` +error[E0391]: cycle detected when computing the super predicates of `T1`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-12511.rs:1:12 | LL | trait T1 : T2 { diff --git a/tests/ui/dyn-star/param-env-region-infer.next.stderr b/tests/ui/dyn-star/param-env-region-infer.next.stderr index 9ea7677389c..8ba18c54ef8 100644 --- a/tests/ui/dyn-star/param-env-region-infer.next.stderr +++ b/tests/ui/dyn-star/param-env-region-infer.next.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `make_dyn_star::{opaque#0}` +error[E0391]: cycle detected when computing type of `make_dyn_star::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/param-env-region-infer.rs:16:60 | LL | fn make_dyn_star<'a, T: PointerLike + Debug + 'a>(t: T) -> impl PointerLike + Debug + 'a { diff --git a/tests/ui/impl-trait/auto-trait-leak.stderr b/tests/ui/impl-trait/auto-trait-leak.stderr index 9c662053c81..72717f116c1 100644 --- a/tests/ui/impl-trait/auto-trait-leak.stderr +++ b/tests/ui/impl-trait/auto-trait-leak.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` +error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/auto-trait-leak.rs:11:16 | LL | fn cycle1() -> impl Clone { @@ -39,7 +39,7 @@ LL | | Rc::new(String::from("foo")) LL | | } | |_^ -error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` +error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/auto-trait-leak.rs:11:16 | LL | fn cycle1() -> impl Clone { diff --git a/tests/ui/infinite/infinite-trait-alias-recursion.stderr b/tests/ui/infinite/infinite-trait-alias-recursion.stderr index 36894dc1894..04392757571 100644 --- a/tests/ui/infinite/infinite-trait-alias-recursion.stderr +++ b/tests/ui/infinite/infinite-trait-alias-recursion.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `T1` +error[E0391]: cycle detected when computing the super predicates of `T1`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/infinite-trait-alias-recursion.rs:3:12 | LL | trait T1 = T2; diff --git a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr index 7a4900e5110..55005ce3515 100644 --- a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr +++ b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when expanding type alias `X1` +error[E0391]: cycle detected when expanding type alias `X1`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/infinite-type-alias-mutual-recursion.rs:1:11 | LL | type X1 = X2; diff --git a/tests/ui/infinite/infinite-vec-type-recursion.stderr b/tests/ui/infinite/infinite-vec-type-recursion.stderr index 82a53f13f14..8b9d44e0bd1 100644 --- a/tests/ui/infinite/infinite-vec-type-recursion.stderr +++ b/tests/ui/infinite/infinite-vec-type-recursion.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when expanding type alias `X` +error[E0391]: cycle detected when expanding type alias `X`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/infinite-vec-type-recursion.rs:1:14 | LL | type X = Vec; diff --git a/tests/ui/issues/issue-17252.stderr b/tests/ui/issues/issue-17252.stderr index eaaa6b6dc62..2bec022611e 100644 --- a/tests/ui/issues/issue-17252.stderr +++ b/tests/ui/issues/issue-17252.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO` +error[E0391]: cycle detected when const-evaluating + checking `FOO`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-17252.rs:1:20 | LL | const FOO: usize = FOO; diff --git a/tests/ui/issues/issue-20772.stderr b/tests/ui/issues/issue-20772.stderr index 1d51be58954..1a3c4feff0f 100644 --- a/tests/ui/issues/issue-20772.stderr +++ b/tests/ui/issues/issue-20772.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super traits of `T` with associated type name `Item` +error[E0391]: cycle detected when computing the super traits of `T` with associated type name `Item`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-20772.rs:1:1 | LL | trait T : Iterator diff --git a/tests/ui/issues/issue-21177.stderr b/tests/ui/issues/issue-21177.stderr index b3e550b36d8..2f8df03834d 100644 --- a/tests/ui/issues/issue-21177.stderr +++ b/tests/ui/issues/issue-21177.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the bounds for type parameter `T` +error[E0391]: cycle detected when computing the bounds for type parameter `T`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-21177.rs:6:21 | LL | fn foo>() { } diff --git a/tests/ui/issues/issue-23302-1.stderr b/tests/ui/issues/issue-23302-1.stderr index 86773f13511..3c77582d19f 100644 --- a/tests/ui/issues/issue-23302-1.stderr +++ b/tests/ui/issues/issue-23302-1.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `X::A::{constant#0}` +error[E0391]: cycle detected when const-evaluating + checking `X::A::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-23302-1.rs:4:9 | LL | A = X::A as isize, diff --git a/tests/ui/issues/issue-23302-2.stderr b/tests/ui/issues/issue-23302-2.stderr index 67d07219d16..fb2c4b5b483 100644 --- a/tests/ui/issues/issue-23302-2.stderr +++ b/tests/ui/issues/issue-23302-2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `Y::A::{constant#0}` +error[E0391]: cycle detected when const-evaluating + checking `Y::A::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-23302-2.rs:4:9 | LL | A = Y::B as isize, diff --git a/tests/ui/issues/issue-23302-3.stderr b/tests/ui/issues/issue-23302-3.stderr index 0cbeee1d079..253eca73510 100644 --- a/tests/ui/issues/issue-23302-3.stderr +++ b/tests/ui/issues/issue-23302-3.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `A` +error[E0391]: cycle detected when const-evaluating + checking `A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-23302-3.rs:1:16 | LL | const A: i32 = B; diff --git a/tests/ui/issues/issue-34373.stderr b/tests/ui/issues/issue-34373.stderr index e2c0c9182bb..045a82f8779 100644 --- a/tests/ui/issues/issue-34373.stderr +++ b/tests/ui/issues/issue-34373.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Foo::T` +error[E0391]: cycle detected when computing type of `Foo::T`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-34373.rs:7:30 | LL | pub struct Foo>>; diff --git a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr index cdd4937e724..590c818c726 100644 --- a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr +++ b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing layout of `core::option::Option` +error[E0391]: cycle detected when computing layout of `core::option::Option`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. | = 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 = note: ...which requires computing layout of `S`... diff --git a/tests/ui/recursion/recursive-static-definition.stderr b/tests/ui/recursion/recursive-static-definition.stderr index 85ca99bef45..1d5c91913a6 100644 --- a/tests/ui/recursion/recursive-static-definition.stderr +++ b/tests/ui/recursion/recursive-static-definition.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO` +error[E0391]: cycle detected when const-evaluating + checking `FOO`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/recursive-static-definition.rs:1:1 | LL | pub static FOO: u32 = FOO; diff --git a/tests/ui/resolve/resolve-self-in-impl.stderr b/tests/ui/resolve/resolve-self-in-impl.stderr index f9dc44d5b9a..e245c10db0f 100644 --- a/tests/ui/resolve/resolve-self-in-impl.stderr +++ b/tests/ui/resolve/resolve-self-in-impl.stderr @@ -38,7 +38,7 @@ LL | impl (Self, Self) {} | = note: replace `Self` with a different type -error[E0391]: cycle detected when computing trait implemented by `` +error[E0391]: cycle detected when computing trait implemented by ``. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/resolve-self-in-impl.rs:19:1 | LL | impl Tr for S {} diff --git a/tests/ui/sized/recursive-type-2.stderr b/tests/ui/sized/recursive-type-2.stderr index 574c0e0021f..b4dbe5333b5 100644 --- a/tests/ui/sized/recursive-type-2.stderr +++ b/tests/ui/sized/recursive-type-2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing layout of `Foo<()>` +error[E0391]: cycle detected when computing layout of `Foo<()>`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. | = 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 = note: ...which requires computing layout of `<() as A>::Assoc`... diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs index 511e41562b2..8efe17d5d0e 100644 --- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs +++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs @@ -1,5 +1,5 @@ trait A: B + A {} -//~^ ERROR cycle detected when computing the super predicates of `A` [E0391] +//~^ ERROR cycle detected when computing the super predicates of `A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] trait B {} diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr index af1fa1594ce..cdb26df0e5c 100644 --- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr +++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `A` +error[E0391]: cycle detected when computing the super predicates of `A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/cyclic-trait-resolution.rs:1:14 | LL | trait A: B + A {} diff --git a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr index be76d0b2621..bf1c3d1fc76 100644 --- a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr +++ b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when simplifying constant for the type system `Alpha::V3::{constant#0}` +error[E0391]: cycle detected when simplifying constant for the type system `Alpha::V3::{constant#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/self-in-enum-definition.rs:5:10 | LL | V3 = Self::V1 {} as u8 + 2, diff --git a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs index fd3f9c61420..a1c91329246 100644 --- a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs +++ b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs @@ -5,8 +5,8 @@ mod m { pub type Foo = impl std::fmt::Debug; - //~^ ERROR: cycle detected when computing type of `m::Foo::{opaque#0}` [E0391] - //~| ERROR: cycle detected when computing type of `m::Foo::{opaque#0}` [E0391] + //~^ ERROR: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] + //~| ERROR: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] pub fn foo() -> Foo { 22_u32 diff --git a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr index fb414bca91e..fcb06240f9e 100644 --- a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr +++ b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/auto-trait-leakage3.rs:7:20 | LL | pub type Foo = impl std::fmt::Debug; @@ -22,7 +22,7 @@ note: cycle used when checking item types in module `m` LL | mod m { | ^^^^^ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/auto-trait-leakage3.rs:7:20 | LL | pub type Foo = impl std::fmt::Debug; diff --git a/tests/ui/type-alias-impl-trait/inference-cycle.stderr b/tests/ui/type-alias-impl-trait/inference-cycle.stderr index 6a14ec8f099..07f934dc8a9 100644 --- a/tests/ui/type-alias-impl-trait/inference-cycle.stderr +++ b/tests/ui/type-alias-impl-trait/inference-cycle.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/inference-cycle.rs:5:20 | LL | pub type Foo = impl std::fmt::Debug; @@ -22,7 +22,7 @@ note: cycle used when checking item types in module `m` LL | mod m { | ^^^^^ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/inference-cycle.rs:5:20 | LL | pub type Foo = impl std::fmt::Debug; diff --git a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr index e23b9f3845c..8e1b9e10469 100644 --- a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr +++ b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Bug::{opaque#0}` +error[E0391]: cycle detected when computing type of `Bug::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/issue-53092-2.rs:4:18 | LL | type Bug = impl Fn(T) -> U + Copy; diff --git a/tests/ui/type-alias-impl-trait/reveal_local.stderr b/tests/ui/type-alias-impl-trait/reveal_local.stderr index 6c5fe8cf32f..46f61ffc335 100644 --- a/tests/ui/type-alias-impl-trait/reveal_local.stderr +++ b/tests/ui/type-alias-impl-trait/reveal_local.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; @@ -28,7 +28,7 @@ LL | | LL | | fn main() {} | |____________^ -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; @@ -79,7 +79,7 @@ note: required by a bound in `is_send` LL | fn is_send() {} | ^^^^ required by this bound in `is_send` -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}` +error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; From e6e88920514d2428130fe1d95ae30ae538ac8644 Mon Sep 17 00:00:00 2001 From: nxya Date: Wed, 12 Jul 2023 22:59:01 -0400 Subject: [PATCH 5/7] added links as a note --- tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr | 2 +- tests/ui/associated-consts/defaults-cyclic-fail.stderr | 2 +- .../issue-24949-assoc-const-static-recursion-impl.stderr | 2 +- ...-24949-assoc-const-static-recursion-trait-default.stderr | 2 +- .../issue-24949-assoc-const-static-recursion-trait.stderr | 2 +- .../bugs/cycle-iat-inside-of-adt.stderr | 2 +- .../bugs/cycle-iat-inside-of-where-predicate.stderr | 2 +- .../ui/associated-type-bounds/ambiguous-associated-type2.rs | 2 +- .../ambiguous-associated-type2.stderr | 2 +- tests/ui/associated-types/issue-20825.stderr | 2 +- .../coherence/coherence-inherited-assoc-ty-cycle-err.stderr | 2 +- tests/ui/const-generics/generic_const_exprs/closures.stderr | 2 +- tests/ui/const-generics/issues/issue-83765.stderr | 2 +- tests/ui/consts/const-size_of-cycle.stderr | 2 +- tests/ui/consts/issue-103790.stderr | 4 ++-- tests/ui/consts/issue-36163.stderr | 2 +- tests/ui/consts/issue-44415.stderr | 2 +- tests/ui/consts/recursive-zst-static.default.stderr | 2 +- tests/ui/consts/recursive-zst-static.unleash.stderr | 2 +- tests/ui/consts/write-to-static-mut-in-static.stderr | 2 +- tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr | 2 +- tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr | 2 +- tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr | 2 +- tests/ui/cycle-trait/issue-12511.stderr | 2 +- tests/ui/dyn-star/param-env-region-infer.next.stderr | 2 +- tests/ui/impl-trait/auto-trait-leak.stderr | 4 ++-- tests/ui/infinite/infinite-trait-alias-recursion.stderr | 2 +- .../ui/infinite/infinite-type-alias-mutual-recursion.stderr | 2 +- tests/ui/infinite/infinite-vec-type-recursion.stderr | 2 +- tests/ui/issues/issue-17252.stderr | 2 +- tests/ui/issues/issue-20772.stderr | 2 +- tests/ui/issues/issue-21177.stderr | 2 +- tests/ui/issues/issue-23302-1.stderr | 2 +- tests/ui/issues/issue-23302-2.stderr | 2 +- tests/ui/issues/issue-23302-3.stderr | 2 +- tests/ui/issues/issue-34373.stderr | 2 +- .../ui/recursion/issue-26548-recursion-via-normalize.stderr | 2 +- tests/ui/recursion/recursive-static-definition.stderr | 2 +- tests/ui/resolve/resolve-self-in-impl.stderr | 2 +- tests/ui/sized/recursive-type-2.stderr | 2 +- tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs | 2 +- .../traits/trait-upcasting/cyclic-trait-resolution.stderr | 2 +- .../type-alias-enum-variants/self-in-enum-definition.stderr | 2 +- tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs | 4 ++-- tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr | 4 ++-- tests/ui/type-alias-impl-trait/inference-cycle.stderr | 4 ++-- tests/ui/type-alias-impl-trait/issue-53092-2.stderr | 2 +- tests/ui/type-alias-impl-trait/reveal_local.stderr | 6 +++--- 48 files changed, 55 insertions(+), 55 deletions(-) diff --git a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr index cc2fbfd5420..777b4c46798 100644 --- a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr +++ b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when expanding type alias `Bar`. 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[E0391]: cycle detected when expanding type alias `Bar` --> $DIR/issue-110629-private-type-cycle-dyn.rs:1:38 | LL | type Bar<'a, 'b> = Box>>; diff --git a/tests/ui/associated-consts/defaults-cyclic-fail.stderr b/tests/ui/associated-consts/defaults-cyclic-fail.stderr index 10a6417f658..d6a13ae4dbf 100644 --- a/tests/ui/associated-consts/defaults-cyclic-fail.stderr +++ b/tests/ui/associated-consts/defaults-cyclic-fail.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `Tr::A`. 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[E0391]: cycle detected when const-evaluating + checking `Tr::A` --> $DIR/defaults-cyclic-fail.rs:5:19 | LL | const A: u8 = Self::B; diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr index 5c15bc262cc..40b3bcec243 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when elaborating drops for `::BAR`. 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[E0391]: cycle detected when elaborating drops for `::BAR` --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:12:22 | LL | const BAR: u32 = IMPL_REF_BAR; diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr index ab85dc78fc1..e58d93de59d 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when elaborating drops for `FooDefault::BAR`. 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[E0391]: cycle detected when elaborating drops for `FooDefault::BAR` --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:8:22 | LL | const BAR: u32 = DEFAULT_REF_BAR; diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr index 48c1c32a1e2..6a97ea64dde 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when elaborating drops for `::BAR`. 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[E0391]: cycle detected when elaborating drops for `::BAR` --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:12:22 | LL | const BAR: u32 = TRAIT_REF_BAR; diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr index 6e3864ebf28..f088ecba4a8 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing predicates of `Foo`. 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[E0391]: cycle detected when computing predicates of `Foo` --> $DIR/cycle-iat-inside-of-adt.rs:7:1 | LL | struct Foo { diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr index 64616c20661..cfc16d622e9 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing predicates of `user`. 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[E0391]: cycle detected when computing predicates of `user` --> $DIR/cycle-iat-inside-of-where-predicate.rs:8:1 | LL | fn user() where S::P: std::fmt::Debug {} diff --git a/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs b/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs index b7a60a2cba4..e9cd57f1739 100644 --- a/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs +++ b/tests/ui/associated-type-bounds/ambiguous-associated-type2.rs @@ -5,7 +5,7 @@ trait Bar { type Item; } trait Baz: Foo + Bar {} -//~^ ERROR cycle detected when computing the super traits of `Baz` with associated type name `Item`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] +//~^ ERROR cycle detected when computing the super traits of `Baz` with associated type name `Item` [E0391] diff --git a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr index 6a55afc4027..4bf53f46233 100644 --- a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr +++ b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super traits of `Baz` with associated type name `Item`. 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[E0391]: cycle detected when computing the super traits of `Baz` with associated type name `Item` --> $DIR/ambiguous-associated-type2.rs:7:1 | LL | trait Baz: Foo + Bar {} diff --git a/tests/ui/associated-types/issue-20825.stderr b/tests/ui/associated-types/issue-20825.stderr index 2f2d9c20dd4..068f049cae5 100644 --- a/tests/ui/associated-types/issue-20825.stderr +++ b/tests/ui/associated-types/issue-20825.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super traits of `Processor` with associated type name `Input`. 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[E0391]: cycle detected when computing the super traits of `Processor` with associated type name `Input` --> $DIR/issue-20825.rs:5:1 | LL | pub trait Processor: Subscriber { diff --git a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr index c9ee2340bab..91e45b0ccb1 100644 --- a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr +++ b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr @@ -8,7 +8,7 @@ LL | #![feature(specialization)] = help: consider using `min_specialization` instead, which is more stable and complete = note: `#[warn(incomplete_features)]` on by default -error[E0391]: cycle detected when building specialization graph of trait `Trait`. 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[E0391]: cycle detected when building specialization graph of trait `Trait` --> $DIR/coherence-inherited-assoc-ty-cycle-err.rs:9:1 | LL | trait Trait { type Assoc; } diff --git a/tests/ui/const-generics/generic_const_exprs/closures.stderr b/tests/ui/const-generics/generic_const_exprs/closures.stderr index 8c158555f50..976cd67937a 100644 --- a/tests/ui/const-generics/generic_const_exprs/closures.stderr +++ b/tests/ui/const-generics/generic_const_exprs/closures.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when building an abstract representation for `test::{constant#0}`. 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[E0391]: cycle detected when building an abstract representation for `test::{constant#0}` --> $DIR/closures.rs:3:35 | LL | fn test() -> [u8; N + (|| 42)()] {} diff --git a/tests/ui/const-generics/issues/issue-83765.stderr b/tests/ui/const-generics/issues/issue-83765.stderr index 656e5ca02d1..bec7eca089d 100644 --- a/tests/ui/const-generics/issues/issue-83765.stderr +++ b/tests/ui/const-generics/issues/issue-83765.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when resolving instance `::DIM, DIM> as TensorDimension>::DIM`. 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[E0391]: cycle detected when resolving instance `::DIM, DIM> as TensorDimension>::DIM` --> $DIR/issue-83765.rs:5:5 | LL | const DIM: usize; diff --git a/tests/ui/consts/const-size_of-cycle.stderr b/tests/ui/consts/const-size_of-cycle.stderr index 8211bb53670..3a18c769246 100644 --- a/tests/ui/consts/const-size_of-cycle.stderr +++ b/tests/ui/consts/const-size_of-cycle.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when evaluating type-level constant. 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[E0391]: cycle detected when evaluating type-level constant --> $DIR/const-size_of-cycle.rs:4:17 | LL | bytes: [u8; std::mem::size_of::()] diff --git a/tests/ui/consts/issue-103790.stderr b/tests/ui/consts/issue-103790.stderr index feb6138ced8..917c8b1173e 100644 --- a/tests/ui/consts/issue-103790.stderr +++ b/tests/ui/consts/issue-103790.stderr @@ -22,7 +22,7 @@ help: add missing generic argument LL | struct S = { S }>; | +++ -error[E0391]: cycle detected when computing type of `S::S`. 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[E0391]: cycle detected when computing type of `S::S` --> $DIR/issue-103790.rs:4:32 | LL | struct S; @@ -40,7 +40,7 @@ note: cycle used when computing type of `S` LL | struct S; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -error[E0391]: cycle detected when computing type of `S`. 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[E0391]: cycle detected when computing type of `S` --> $DIR/issue-103790.rs:4:1 | LL | struct S; diff --git a/tests/ui/consts/issue-36163.stderr b/tests/ui/consts/issue-36163.stderr index de506b4c614..fb2866554ff 100644 --- a/tests/ui/consts/issue-36163.stderr +++ b/tests/ui/consts/issue-36163.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `Foo::B::{constant#0}`. 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[E0391]: cycle detected when const-evaluating + checking `Foo::B::{constant#0}` --> $DIR/issue-36163.rs:4:9 | LL | B = A, diff --git a/tests/ui/consts/issue-44415.stderr b/tests/ui/consts/issue-44415.stderr index d258f48f4ee..12284ff2fb2 100644 --- a/tests/ui/consts/issue-44415.stderr +++ b/tests/ui/consts/issue-44415.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when evaluating type-level constant. 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[E0391]: cycle detected when evaluating type-level constant --> $DIR/issue-44415.rs:6:17 | LL | bytes: [u8; unsafe { intrinsics::size_of::() }], diff --git a/tests/ui/consts/recursive-zst-static.default.stderr b/tests/ui/consts/recursive-zst-static.default.stderr index f57ae40dac3..7f9d7c1cb8b 100644 --- a/tests/ui/consts/recursive-zst-static.default.stderr +++ b/tests/ui/consts/recursive-zst-static.default.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO`. 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[E0391]: cycle detected when const-evaluating + checking `FOO` --> $DIR/recursive-zst-static.rs:10:1 | LL | static FOO: () = FOO; diff --git a/tests/ui/consts/recursive-zst-static.unleash.stderr b/tests/ui/consts/recursive-zst-static.unleash.stderr index f57ae40dac3..7f9d7c1cb8b 100644 --- a/tests/ui/consts/recursive-zst-static.unleash.stderr +++ b/tests/ui/consts/recursive-zst-static.unleash.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO`. 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[E0391]: cycle detected when const-evaluating + checking `FOO` --> $DIR/recursive-zst-static.rs:10:1 | LL | static FOO: () = FOO; diff --git a/tests/ui/consts/write-to-static-mut-in-static.stderr b/tests/ui/consts/write-to-static-mut-in-static.stderr index a88d09f54b3..74c636c357b 100644 --- a/tests/ui/consts/write-to-static-mut-in-static.stderr +++ b/tests/ui/consts/write-to-static-mut-in-static.stderr @@ -4,7 +4,7 @@ error[E0080]: could not evaluate static initializer LL | pub static mut B: () = unsafe { A = 1; }; | ^^^^^ modifying a static's initial value from another static's initializer -error[E0391]: cycle detected when const-evaluating + checking `C`. 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[E0391]: cycle detected when const-evaluating + checking `C` --> $DIR/write-to-static-mut-in-static.rs:5:1 | LL | pub static mut C: u32 = unsafe { C = 1; 0 }; diff --git a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr index 39d4a96da29..3c1f7198de7 100644 --- a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr +++ b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Foo::X`. 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[E0391]: cycle detected when computing type of `Foo::X` --> $DIR/cycle-trait-default-type-trait.rs:4:23 | LL | trait Foo> { diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr index 69c1b47ab96..26ae7869524 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `Chromosome`. 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[E0391]: cycle detected when computing the super predicates of `Chromosome` --> $DIR/cycle-trait-supertrait-direct.rs:3:19 | LL | trait Chromosome: Chromosome { diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr index 42ecd262545..ec4f4a6ca53 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `B`. 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[E0391]: cycle detected when computing the super predicates of `B` --> $DIR/cycle-trait-supertrait-indirect.rs:7:10 | LL | trait B: C { diff --git a/tests/ui/cycle-trait/issue-12511.stderr b/tests/ui/cycle-trait/issue-12511.stderr index 000726d5585..1e7152fbb39 100644 --- a/tests/ui/cycle-trait/issue-12511.stderr +++ b/tests/ui/cycle-trait/issue-12511.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `T1`. 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[E0391]: cycle detected when computing the super predicates of `T1` --> $DIR/issue-12511.rs:1:12 | LL | trait T1 : T2 { diff --git a/tests/ui/dyn-star/param-env-region-infer.next.stderr b/tests/ui/dyn-star/param-env-region-infer.next.stderr index 8ba18c54ef8..9ea7677389c 100644 --- a/tests/ui/dyn-star/param-env-region-infer.next.stderr +++ b/tests/ui/dyn-star/param-env-region-infer.next.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `make_dyn_star::{opaque#0}`. 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[E0391]: cycle detected when computing type of `make_dyn_star::{opaque#0}` --> $DIR/param-env-region-infer.rs:16:60 | LL | fn make_dyn_star<'a, T: PointerLike + Debug + 'a>(t: T) -> impl PointerLike + Debug + 'a { diff --git a/tests/ui/impl-trait/auto-trait-leak.stderr b/tests/ui/impl-trait/auto-trait-leak.stderr index 72717f116c1..9c662053c81 100644 --- a/tests/ui/impl-trait/auto-trait-leak.stderr +++ b/tests/ui/impl-trait/auto-trait-leak.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}`. 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[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` --> $DIR/auto-trait-leak.rs:11:16 | LL | fn cycle1() -> impl Clone { @@ -39,7 +39,7 @@ LL | | Rc::new(String::from("foo")) LL | | } | |_^ -error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}`. 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[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` --> $DIR/auto-trait-leak.rs:11:16 | LL | fn cycle1() -> impl Clone { diff --git a/tests/ui/infinite/infinite-trait-alias-recursion.stderr b/tests/ui/infinite/infinite-trait-alias-recursion.stderr index 04392757571..36894dc1894 100644 --- a/tests/ui/infinite/infinite-trait-alias-recursion.stderr +++ b/tests/ui/infinite/infinite-trait-alias-recursion.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `T1`. 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[E0391]: cycle detected when computing the super predicates of `T1` --> $DIR/infinite-trait-alias-recursion.rs:3:12 | LL | trait T1 = T2; diff --git a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr index 55005ce3515..7a4900e5110 100644 --- a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr +++ b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when expanding type alias `X1`. 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[E0391]: cycle detected when expanding type alias `X1` --> $DIR/infinite-type-alias-mutual-recursion.rs:1:11 | LL | type X1 = X2; diff --git a/tests/ui/infinite/infinite-vec-type-recursion.stderr b/tests/ui/infinite/infinite-vec-type-recursion.stderr index 8b9d44e0bd1..82a53f13f14 100644 --- a/tests/ui/infinite/infinite-vec-type-recursion.stderr +++ b/tests/ui/infinite/infinite-vec-type-recursion.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when expanding type alias `X`. 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[E0391]: cycle detected when expanding type alias `X` --> $DIR/infinite-vec-type-recursion.rs:1:14 | LL | type X = Vec; diff --git a/tests/ui/issues/issue-17252.stderr b/tests/ui/issues/issue-17252.stderr index 2bec022611e..eaaa6b6dc62 100644 --- a/tests/ui/issues/issue-17252.stderr +++ b/tests/ui/issues/issue-17252.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO`. 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[E0391]: cycle detected when const-evaluating + checking `FOO` --> $DIR/issue-17252.rs:1:20 | LL | const FOO: usize = FOO; diff --git a/tests/ui/issues/issue-20772.stderr b/tests/ui/issues/issue-20772.stderr index 1a3c4feff0f..1d51be58954 100644 --- a/tests/ui/issues/issue-20772.stderr +++ b/tests/ui/issues/issue-20772.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super traits of `T` with associated type name `Item`. 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[E0391]: cycle detected when computing the super traits of `T` with associated type name `Item` --> $DIR/issue-20772.rs:1:1 | LL | trait T : Iterator diff --git a/tests/ui/issues/issue-21177.stderr b/tests/ui/issues/issue-21177.stderr index 2f8df03834d..b3e550b36d8 100644 --- a/tests/ui/issues/issue-21177.stderr +++ b/tests/ui/issues/issue-21177.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the bounds for type parameter `T`. 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[E0391]: cycle detected when computing the bounds for type parameter `T` --> $DIR/issue-21177.rs:6:21 | LL | fn foo>() { } diff --git a/tests/ui/issues/issue-23302-1.stderr b/tests/ui/issues/issue-23302-1.stderr index 3c77582d19f..86773f13511 100644 --- a/tests/ui/issues/issue-23302-1.stderr +++ b/tests/ui/issues/issue-23302-1.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `X::A::{constant#0}`. 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[E0391]: cycle detected when const-evaluating + checking `X::A::{constant#0}` --> $DIR/issue-23302-1.rs:4:9 | LL | A = X::A as isize, diff --git a/tests/ui/issues/issue-23302-2.stderr b/tests/ui/issues/issue-23302-2.stderr index fb2c4b5b483..67d07219d16 100644 --- a/tests/ui/issues/issue-23302-2.stderr +++ b/tests/ui/issues/issue-23302-2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `Y::A::{constant#0}`. 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[E0391]: cycle detected when const-evaluating + checking `Y::A::{constant#0}` --> $DIR/issue-23302-2.rs:4:9 | LL | A = Y::B as isize, diff --git a/tests/ui/issues/issue-23302-3.stderr b/tests/ui/issues/issue-23302-3.stderr index 253eca73510..0cbeee1d079 100644 --- a/tests/ui/issues/issue-23302-3.stderr +++ b/tests/ui/issues/issue-23302-3.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `A`. 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[E0391]: cycle detected when const-evaluating + checking `A` --> $DIR/issue-23302-3.rs:1:16 | LL | const A: i32 = B; diff --git a/tests/ui/issues/issue-34373.stderr b/tests/ui/issues/issue-34373.stderr index 045a82f8779..e2c0c9182bb 100644 --- a/tests/ui/issues/issue-34373.stderr +++ b/tests/ui/issues/issue-34373.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Foo::T`. 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[E0391]: cycle detected when computing type of `Foo::T` --> $DIR/issue-34373.rs:7:30 | LL | pub struct Foo>>; diff --git a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr index 590c818c726..cdd4937e724 100644 --- a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr +++ b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing layout of `core::option::Option`. 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[E0391]: cycle detected when computing layout of `core::option::Option` | = 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 = note: ...which requires computing layout of `S`... diff --git a/tests/ui/recursion/recursive-static-definition.stderr b/tests/ui/recursion/recursive-static-definition.stderr index 1d5c91913a6..85ca99bef45 100644 --- a/tests/ui/recursion/recursive-static-definition.stderr +++ b/tests/ui/recursion/recursive-static-definition.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when const-evaluating + checking `FOO`. 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[E0391]: cycle detected when const-evaluating + checking `FOO` --> $DIR/recursive-static-definition.rs:1:1 | LL | pub static FOO: u32 = FOO; diff --git a/tests/ui/resolve/resolve-self-in-impl.stderr b/tests/ui/resolve/resolve-self-in-impl.stderr index e245c10db0f..f9dc44d5b9a 100644 --- a/tests/ui/resolve/resolve-self-in-impl.stderr +++ b/tests/ui/resolve/resolve-self-in-impl.stderr @@ -38,7 +38,7 @@ LL | impl (Self, Self) {} | = note: replace `Self` with a different type -error[E0391]: cycle detected when computing trait implemented by ``. 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[E0391]: cycle detected when computing trait implemented by `` --> $DIR/resolve-self-in-impl.rs:19:1 | LL | impl Tr for S {} diff --git a/tests/ui/sized/recursive-type-2.stderr b/tests/ui/sized/recursive-type-2.stderr index b4dbe5333b5..574c0e0021f 100644 --- a/tests/ui/sized/recursive-type-2.stderr +++ b/tests/ui/sized/recursive-type-2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing layout of `Foo<()>`. 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[E0391]: cycle detected when computing layout of `Foo<()>` | = 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 = note: ...which requires computing layout of `<() as A>::Assoc`... diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs index 8efe17d5d0e..511e41562b2 100644 --- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs +++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.rs @@ -1,5 +1,5 @@ trait A: B + A {} -//~^ ERROR cycle detected when computing the super predicates of `A`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] +//~^ ERROR cycle detected when computing the super predicates of `A` [E0391] trait B {} diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr index cdb26df0e5c..af1fa1594ce 100644 --- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr +++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing the super predicates of `A`. 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[E0391]: cycle detected when computing the super predicates of `A` --> $DIR/cyclic-trait-resolution.rs:1:14 | LL | trait A: B + A {} diff --git a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr index bf1c3d1fc76..be76d0b2621 100644 --- a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr +++ b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when simplifying constant for the type system `Alpha::V3::{constant#0}`. 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[E0391]: cycle detected when simplifying constant for the type system `Alpha::V3::{constant#0}` --> $DIR/self-in-enum-definition.rs:5:10 | LL | V3 = Self::V1 {} as u8 + 2, diff --git a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs index a1c91329246..fd3f9c61420 100644 --- a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs +++ b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.rs @@ -5,8 +5,8 @@ mod m { pub type Foo = impl std::fmt::Debug; - //~^ ERROR: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] - //~| ERROR: cycle detected when computing type of `m::Foo::{opaque#0}`. see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information. [E0391] + //~^ ERROR: cycle detected when computing type of `m::Foo::{opaque#0}` [E0391] + //~| ERROR: cycle detected when computing type of `m::Foo::{opaque#0}` [E0391] pub fn foo() -> Foo { 22_u32 diff --git a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr index fcb06240f9e..fb414bca91e 100644 --- a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr +++ b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/auto-trait-leakage3.rs:7:20 | LL | pub type Foo = impl std::fmt::Debug; @@ -22,7 +22,7 @@ note: cycle used when checking item types in module `m` LL | mod m { | ^^^^^ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/auto-trait-leakage3.rs:7:20 | LL | pub type Foo = impl std::fmt::Debug; diff --git a/tests/ui/type-alias-impl-trait/inference-cycle.stderr b/tests/ui/type-alias-impl-trait/inference-cycle.stderr index 07f934dc8a9..6a14ec8f099 100644 --- a/tests/ui/type-alias-impl-trait/inference-cycle.stderr +++ b/tests/ui/type-alias-impl-trait/inference-cycle.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/inference-cycle.rs:5:20 | LL | pub type Foo = impl std::fmt::Debug; @@ -22,7 +22,7 @@ note: cycle used when checking item types in module `m` LL | mod m { | ^^^^^ -error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/inference-cycle.rs:5:20 | LL | pub type Foo = impl std::fmt::Debug; diff --git a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr index 8e1b9e10469..e23b9f3845c 100644 --- a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr +++ b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Bug::{opaque#0}`. 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[E0391]: cycle detected when computing type of `Bug::{opaque#0}` --> $DIR/issue-53092-2.rs:4:18 | LL | type Bug = impl Fn(T) -> U + Copy; diff --git a/tests/ui/type-alias-impl-trait/reveal_local.stderr b/tests/ui/type-alias-impl-trait/reveal_local.stderr index 46f61ffc335..6c5fe8cf32f 100644 --- a/tests/ui/type-alias-impl-trait/reveal_local.stderr +++ b/tests/ui/type-alias-impl-trait/reveal_local.stderr @@ -1,4 +1,4 @@ -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `Foo::{opaque#0}` --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; @@ -28,7 +28,7 @@ LL | | LL | | fn main() {} | |____________^ -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `Foo::{opaque#0}` --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; @@ -79,7 +79,7 @@ note: required by a bound in `is_send` LL | fn is_send() {} | ^^^^ required by this bound in `is_send` -error[E0391]: cycle detected when computing type of `Foo::{opaque#0}`. 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[E0391]: cycle detected when computing type of `Foo::{opaque#0}` --> $DIR/reveal_local.rs:5:12 | LL | type Foo = impl Debug; From a54a66830db71252f56ac851b9d03e4d8a9d75f4 Mon Sep 17 00:00:00 2001 From: nxya Date: Tue, 18 Jul 2023 21:53:34 -0400 Subject: [PATCH 6/7] moved note as unspanned note, moved note to the bottom of the msg --- compiler/rustc_query_system/src/error.rs | 3 ++- compiler/rustc_query_system/src/query/job.rs | 1 + src/tools/miri/tests/fail/layout_cycle.stderr | 2 +- .../defaults-cyclic-fail.stderr | 6 +----- ...49-assoc-const-static-recursion-impl.stderr | 6 +----- ...const-static-recursion-trait-default.stderr | 6 +----- ...9-assoc-const-static-recursion-trait.stderr | 6 +----- .../bugs/cycle-iat-inside-of-adt.stderr | 6 +----- .../cycle-iat-inside-of-where-predicate.stderr | 6 +----- .../ambiguous-associated-type2.stderr | 6 +----- tests/ui/associated-types/issue-20825.stderr | 6 +----- ...herence-inherited-assoc-ty-cycle-err.stderr | 6 +----- .../generic_const_exprs/closures.stderr | 6 +----- .../const-generics/issues/issue-83765.stderr | 6 +----- tests/ui/consts/const-size_of-cycle.stderr | 6 +----- tests/ui/consts/issue-103790.stderr | 12 ++---------- tests/ui/consts/issue-36163.stderr | 6 +----- tests/ui/consts/issue-44415.stderr | 6 +----- .../consts/recursive-zst-static.default.stderr | 6 +----- .../consts/recursive-zst-static.unleash.stderr | 6 +----- .../write-to-static-mut-in-static.stderr | 6 +----- .../cycle-trait-default-type-trait.stderr | 6 +----- .../cycle-trait-supertrait-direct.stderr | 6 +----- .../cycle-trait-supertrait-indirect.stderr | 6 +----- tests/ui/cycle-trait/issue-12511.stderr | 6 +----- .../param-env-region-infer.next.stderr | 6 +----- tests/ui/impl-trait/auto-trait-leak.stderr | 12 ++---------- .../infinite-trait-alias-recursion.stderr | 6 +----- ...infinite-type-alias-mutual-recursion.stderr | 6 +----- .../infinite-vec-type-recursion.stderr | 6 +----- tests/ui/issues/issue-17252.stderr | 6 +----- tests/ui/issues/issue-20772.stderr | 6 +----- tests/ui/issues/issue-21177.stderr | 6 +----- tests/ui/issues/issue-23302-1.stderr | 6 +----- tests/ui/issues/issue-23302-2.stderr | 6 +----- tests/ui/issues/issue-23302-3.stderr | 6 +----- tests/ui/issues/issue-34373.stderr | 6 +----- .../issue-26548-recursion-via-normalize.stderr | 2 +- .../recursive-static-definition.stderr | 6 +----- tests/ui/resolve/resolve-self-in-impl.stderr | 6 +----- tests/ui/sized/recursive-type-2.stderr | 2 +- .../cyclic-trait-resolution.stderr | 6 +----- .../self-in-enum-definition.stderr | 6 +----- .../auto-trait-leakage3.stderr | 12 ++---------- .../inference-cycle.stderr | 12 ++---------- .../type-alias-impl-trait/issue-53092-2.stderr | 6 +----- .../type-alias-impl-trait/reveal_local.stderr | 18 +++--------------- 47 files changed, 54 insertions(+), 244 deletions(-) diff --git a/compiler/rustc_query_system/src/error.rs b/compiler/rustc_query_system/src/error.rs index 8ed559f2b72..e49e78cc7c4 100644 --- a/compiler/rustc_query_system/src/error.rs +++ b/compiler/rustc_query_system/src/error.rs @@ -46,7 +46,6 @@ pub struct CycleUsage { #[derive(Diagnostic)] #[diag(query_system_cycle, code = "E0391")] pub struct Cycle { - #[note] #[primary_span] pub span: Span, pub stack_bottom: String, @@ -58,6 +57,8 @@ pub struct Cycle { pub alias: Option, #[subdiagnostic] pub cycle_usage: Option, + #[note] + pub note_span: (), } #[derive(Diagnostic)] diff --git a/compiler/rustc_query_system/src/query/job.rs b/compiler/rustc_query_system/src/query/job.rs index f45f7ca5da6..1e301ea2619 100644 --- a/compiler/rustc_query_system/src/query/job.rs +++ b/compiler/rustc_query_system/src/query/job.rs @@ -607,6 +607,7 @@ pub(crate) fn report_cycle<'a, D: DepKind>( alias, cycle_usage: cycle_usage, stack_count, + note_span: (), }; cycle_diag.into_diagnostic(&sess.parse_sess.span_diagnostic) diff --git a/src/tools/miri/tests/fail/layout_cycle.stderr b/src/tools/miri/tests/fail/layout_cycle.stderr index 011b1adab95..38907a1c50c 100644 --- a/src/tools/miri/tests/fail/layout_cycle.stderr +++ b/src/tools/miri/tests/fail/layout_cycle.stderr @@ -1,8 +1,8 @@ error[E0391]: cycle detected when computing layout of `S>` | - = 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 = note: ...which requires computing layout of ` as Tr>::I`... = note: ...which again requires computing layout of `S>`, completing the cycle + = 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: post-monomorphization error: a cycle occurred during layout computation --> RUSTLIB/core/src/mem/mod.rs:LL:CC diff --git a/tests/ui/associated-consts/defaults-cyclic-fail.stderr b/tests/ui/associated-consts/defaults-cyclic-fail.stderr index d6a13ae4dbf..ebdb76e4286 100644 --- a/tests/ui/associated-consts/defaults-cyclic-fail.stderr +++ b/tests/ui/associated-consts/defaults-cyclic-fail.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when const-evaluating + checking `Tr::A` LL | const A: u8 = Self::B; | ^^^^^^^ | -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 - --> $DIR/defaults-cyclic-fail.rs:5:19 - | -LL | const A: u8 = Self::B; - | ^^^^^^^ note: ...which requires const-evaluating + checking `Tr::B`... --> $DIR/defaults-cyclic-fail.rs:8:19 | @@ -20,6 +15,7 @@ note: cycle used when const-evaluating + checking `main::promoted[1]` | LL | assert_eq!(<() as Tr>::A, 0); | ^^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr index 40b3bcec243..51bf0cb5e5c 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-impl.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when elaborating drops for ` $DIR/issue-24949-assoc-const-static-recursion-impl.rs:12:22 - | -LL | const BAR: u32 = IMPL_REF_BAR; - | ^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `IMPL_REF_BAR`... --> $DIR/issue-24949-assoc-const-static-recursion-impl.rs:7:1 | @@ -31,6 +26,7 @@ LL | const BAR: u32 = IMPL_REF_BAR; | ^^^^^^^^^^^^^^ = note: ...which again requires elaborating drops for `::BAR`, completing the cycle = note: cycle used when running analysis passes on this crate + = 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 previous error diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr index e58d93de59d..8277d41a1c9 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait-default.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when elaborating drops for `FooDefault::BAR` LL | const BAR: u32 = DEFAULT_REF_BAR; | ^^^^^^^^^^^^^^^ | -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 - --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:8:22 - | -LL | const BAR: u32 = DEFAULT_REF_BAR; - | ^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `DEFAULT_REF_BAR`... --> $DIR/issue-24949-assoc-const-static-recursion-trait-default.rs:11:1 | @@ -31,6 +26,7 @@ LL | const BAR: u32 = DEFAULT_REF_BAR; | ^^^^^^^^^^^^^^ = note: ...which again requires elaborating drops for `FooDefault::BAR`, completing the cycle = note: cycle used when running analysis passes on this crate + = 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 previous error diff --git a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr index 6a97ea64dde..9983ba794cd 100644 --- a/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr +++ b/tests/ui/associated-consts/issue-24949-assoc-const-static-recursion-trait.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when elaborating drops for ` $DIR/issue-24949-assoc-const-static-recursion-trait.rs:12:22 - | -LL | const BAR: u32 = TRAIT_REF_BAR; - | ^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `TRAIT_REF_BAR`... --> $DIR/issue-24949-assoc-const-static-recursion-trait.rs:7:1 | @@ -31,6 +26,7 @@ LL | const BAR: u32 = TRAIT_REF_BAR; | ^^^^^^^^^^^^^^ = note: ...which again requires elaborating drops for `::BAR`, completing the cycle = note: cycle used when running analysis passes on this crate + = 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 previous error diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr index f088ecba4a8..3c373f139cb 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-adt.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing predicates of `Foo` LL | struct Foo { | ^^^^^^^^^^ | -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 - --> $DIR/cycle-iat-inside-of-adt.rs:7:1 - | -LL | struct Foo { - | ^^^^^^^^^^ note: ...which requires computing predicates of `Foo`... --> $DIR/cycle-iat-inside-of-adt.rs:7:1 | @@ -42,6 +37,7 @@ LL | | LL | | LL | | fn main() {} | |____________^ + = 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 previous error diff --git a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr index cfc16d622e9..ab6a97b3d85 100644 --- a/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr +++ b/tests/ui/associated-inherent-types/bugs/cycle-iat-inside-of-where-predicate.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing predicates of `user` LL | fn user() where S::P: std::fmt::Debug {} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/cycle-iat-inside-of-where-predicate.rs:8:1 - | -LL | fn user() where S::P: std::fmt::Debug {} - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires computing predicates of `user`... --> $DIR/cycle-iat-inside-of-where-predicate.rs:8:1 | @@ -36,6 +31,7 @@ LL | | // FIXME(inherent_associated_types): This shouldn't lead to a cycle error LL | | LL | | fn main() {} | |____________^ + = 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 previous error diff --git a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr index 4bf53f46233..f2604f0ba88 100644 --- a/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr +++ b/tests/ui/associated-type-bounds/ambiguous-associated-type2.stderr @@ -4,17 +4,13 @@ error[E0391]: cycle detected when computing the super traits of `Baz` with assoc LL | trait Baz: Foo + Bar {} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/ambiguous-associated-type2.rs:7:1 - | -LL | trait Baz: Foo + Bar {} - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: ...which immediately requires computing the super traits of `Baz` with associated type name `Item` again note: cycle used when computing the super predicates of `Baz` --> $DIR/ambiguous-associated-type2.rs:7:1 | LL | trait Baz: Foo + Bar {} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/associated-types/issue-20825.stderr b/tests/ui/associated-types/issue-20825.stderr index 068f049cae5..02b3536e2d1 100644 --- a/tests/ui/associated-types/issue-20825.stderr +++ b/tests/ui/associated-types/issue-20825.stderr @@ -4,17 +4,13 @@ error[E0391]: cycle detected when computing the super traits of `Processor` with LL | pub trait Processor: Subscriber { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/issue-20825.rs:5:1 - | -LL | pub trait Processor: Subscriber { - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: ...which immediately requires computing the super traits of `Processor` with associated type name `Input` again note: cycle used when computing the super predicates of `Processor` --> $DIR/issue-20825.rs:5:1 | LL | pub trait Processor: Subscriber { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr index 91e45b0ccb1..684e528220f 100644 --- a/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr +++ b/tests/ui/coherence/coherence-inherited-assoc-ty-cycle-err.stderr @@ -14,17 +14,13 @@ error[E0391]: cycle detected when building specialization graph of trait `Trait` LL | trait Trait { type Assoc; } | ^^^^^^^^^^^^^^ | -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 - --> $DIR/coherence-inherited-assoc-ty-cycle-err.rs:9:1 - | -LL | trait Trait { type Assoc; } - | ^^^^^^^^^^^^^^ = note: ...which immediately requires building specialization graph of trait `Trait` again note: cycle used when coherence checking all impls of trait `Trait` --> $DIR/coherence-inherited-assoc-ty-cycle-err.rs:9:1 | LL | trait Trait { type Assoc; } | ^^^^^^^^^^^^^^ + = 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 previous error; 1 warning emitted diff --git a/tests/ui/const-generics/generic_const_exprs/closures.stderr b/tests/ui/const-generics/generic_const_exprs/closures.stderr index 976cd67937a..45d7922bd0b 100644 --- a/tests/ui/const-generics/generic_const_exprs/closures.stderr +++ b/tests/ui/const-generics/generic_const_exprs/closures.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when building an abstract representation for `test: LL | fn test() -> [u8; N + (|| 42)()] {} | ^^^^^^^^^^^^^ | -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 - --> $DIR/closures.rs:3:35 - | -LL | fn test() -> [u8; N + (|| 42)()] {} - | ^^^^^^^^^^^^^ note: ...which requires building THIR for `test::{constant#0}`... --> $DIR/closures.rs:3:35 | @@ -25,6 +20,7 @@ note: cycle used when checking that `test` is well-formed | LL | fn test() -> [u8; N + (|| 42)()] {} | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/const-generics/issues/issue-83765.stderr b/tests/ui/const-generics/issues/issue-83765.stderr index bec7eca089d..df734933c25 100644 --- a/tests/ui/const-generics/issues/issue-83765.stderr +++ b/tests/ui/const-generics/issues/issue-83765.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when resolving instance ` $DIR/issue-83765.rs:5:5 - | -LL | const DIM: usize; - | ^^^^^^^^^^^^^^^^ note: ...which requires computing candidate for `::DIM, DIM> as TensorDimension>`... --> $DIR/issue-83765.rs:4:1 | @@ -20,6 +15,7 @@ note: cycle used when computing candidate for `()] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/const-size_of-cycle.rs:4:17 - | -LL | bytes: [u8; std::mem::size_of::()] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `Foo::bytes::{constant#0}`... --> $DIR/const-size_of-cycle.rs:4:17 | @@ -28,6 +23,7 @@ note: cycle used when checking that `Foo` is well-formed | LL | struct Foo { | ^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/consts/issue-103790.stderr b/tests/ui/consts/issue-103790.stderr index 917c8b1173e..67334469dcd 100644 --- a/tests/ui/consts/issue-103790.stderr +++ b/tests/ui/consts/issue-103790.stderr @@ -28,17 +28,13 @@ error[E0391]: cycle detected when computing type of `S::S` LL | struct S; | ^ | -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 - --> $DIR/issue-103790.rs:4:32 - | -LL | struct S; - | ^ = note: ...which immediately requires computing type of `S::S` again note: cycle used when computing type of `S` --> $DIR/issue-103790.rs:4:1 | LL | struct S; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + = 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[E0391]: cycle detected when computing type of `S` --> $DIR/issue-103790.rs:4:1 @@ -46,11 +42,6 @@ error[E0391]: cycle detected when computing type of `S` LL | struct S; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/issue-103790.rs:4:1 - | -LL | struct S; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires computing type of `S::S`... --> $DIR/issue-103790.rs:4:32 | @@ -68,6 +59,7 @@ LL | | struct S; LL | | LL | | fn main() {} | |____________^ + = 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 4 previous errors diff --git a/tests/ui/consts/issue-36163.stderr b/tests/ui/consts/issue-36163.stderr index fb2866554ff..190b41062f8 100644 --- a/tests/ui/consts/issue-36163.stderr +++ b/tests/ui/consts/issue-36163.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when const-evaluating + checking `Foo::B::{constant LL | B = A, | ^ | -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 - --> $DIR/issue-36163.rs:4:9 - | -LL | B = A, - | ^ note: ...which requires const-evaluating + checking `A`... --> $DIR/issue-36163.rs:1:18 | @@ -20,6 +15,7 @@ note: cycle used when simplifying constant for the type system `Foo::B::{constan | LL | B = A, | ^ + = 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 previous error diff --git a/tests/ui/consts/issue-44415.stderr b/tests/ui/consts/issue-44415.stderr index 12284ff2fb2..01d24a62081 100644 --- a/tests/ui/consts/issue-44415.stderr +++ b/tests/ui/consts/issue-44415.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when evaluating type-level constant LL | bytes: [u8; unsafe { intrinsics::size_of::() }], | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/issue-44415.rs:6:17 - | -LL | bytes: [u8; unsafe { intrinsics::size_of::() }], - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `Foo::bytes::{constant#0}`... --> $DIR/issue-44415.rs:6:17 | @@ -28,6 +23,7 @@ note: cycle used when checking that `Foo` is well-formed | LL | struct Foo { | ^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/consts/recursive-zst-static.default.stderr b/tests/ui/consts/recursive-zst-static.default.stderr index 7f9d7c1cb8b..d592b5aeef5 100644 --- a/tests/ui/consts/recursive-zst-static.default.stderr +++ b/tests/ui/consts/recursive-zst-static.default.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when const-evaluating + checking `FOO` LL | static FOO: () = FOO; | ^^^^^^^^^^^^^^ | -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 - --> $DIR/recursive-zst-static.rs:10:1 - | -LL | static FOO: () = FOO; - | ^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `FOO`... --> $DIR/recursive-zst-static.rs:10:18 | @@ -24,6 +19,7 @@ LL | | fn main() { LL | | FOO LL | | } | |_^ + = 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 previous error diff --git a/tests/ui/consts/recursive-zst-static.unleash.stderr b/tests/ui/consts/recursive-zst-static.unleash.stderr index 7f9d7c1cb8b..d592b5aeef5 100644 --- a/tests/ui/consts/recursive-zst-static.unleash.stderr +++ b/tests/ui/consts/recursive-zst-static.unleash.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when const-evaluating + checking `FOO` LL | static FOO: () = FOO; | ^^^^^^^^^^^^^^ | -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 - --> $DIR/recursive-zst-static.rs:10:1 - | -LL | static FOO: () = FOO; - | ^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `FOO`... --> $DIR/recursive-zst-static.rs:10:18 | @@ -24,6 +19,7 @@ LL | | fn main() { LL | | FOO LL | | } | |_^ + = 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 previous error diff --git a/tests/ui/consts/write-to-static-mut-in-static.stderr b/tests/ui/consts/write-to-static-mut-in-static.stderr index 74c636c357b..5665e56439e 100644 --- a/tests/ui/consts/write-to-static-mut-in-static.stderr +++ b/tests/ui/consts/write-to-static-mut-in-static.stderr @@ -10,11 +10,6 @@ error[E0391]: cycle detected when const-evaluating + checking `C` LL | pub static mut C: u32 = unsafe { C = 1; 0 }; | ^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/write-to-static-mut-in-static.rs:5:1 - | -LL | pub static mut C: u32 = unsafe { C = 1; 0 }; - | ^^^^^^^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `C`... --> $DIR/write-to-static-mut-in-static.rs:5:34 | @@ -32,6 +27,7 @@ LL | | LL | | LL | | fn main() {} | |____________^ + = 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 2 previous errors diff --git a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr index 3c1f7198de7..3b66704d613 100644 --- a/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr +++ b/tests/ui/cycle-trait/cycle-trait-default-type-trait.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing type of `Foo::X` LL | trait Foo> { | ^^^ | -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 - --> $DIR/cycle-trait-default-type-trait.rs:4:23 - | -LL | trait Foo> { - | ^^^ = note: ...which immediately requires computing type of `Foo::X` again note: cycle used when collecting item types in top-level module --> $DIR/cycle-trait-default-type-trait.rs:4:1 @@ -19,6 +14,7 @@ LL | | } LL | | LL | | fn main() { } | |_____________^ + = 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 previous error diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr index 26ae7869524..03cb5015ab0 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-direct.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing the super predicates of `Chromosome` LL | trait Chromosome: Chromosome { | ^^^^^^^^^^ | -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 - --> $DIR/cycle-trait-supertrait-direct.rs:3:19 - | -LL | trait Chromosome: Chromosome { - | ^^^^^^^^^^ = note: ...which immediately requires computing the super predicates of `Chromosome` again note: cycle used when collecting item types in top-level module --> $DIR/cycle-trait-supertrait-direct.rs:3:1 @@ -17,6 +12,7 @@ LL | / trait Chromosome: Chromosome { LL | | LL | | } | |_^ + = 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 previous error diff --git a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr index ec4f4a6ca53..c7cc3143520 100644 --- a/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr +++ b/tests/ui/cycle-trait/cycle-trait-supertrait-indirect.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing the super predicates of `B` LL | trait B: C { | ^ | -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 - --> $DIR/cycle-trait-supertrait-indirect.rs:7:10 - | -LL | trait B: C { - | ^ note: ...which requires computing the super predicates of `C`... --> $DIR/cycle-trait-supertrait-indirect.rs:11:10 | @@ -20,6 +15,7 @@ note: cycle used when computing the super predicates of `A` | LL | trait A: B { | ^ + = 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 previous error diff --git a/tests/ui/cycle-trait/issue-12511.stderr b/tests/ui/cycle-trait/issue-12511.stderr index 1e7152fbb39..f5e4f83473d 100644 --- a/tests/ui/cycle-trait/issue-12511.stderr +++ b/tests/ui/cycle-trait/issue-12511.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing the super predicates of `T1` LL | trait T1 : T2 { | ^^ | -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 - --> $DIR/issue-12511.rs:1:12 - | -LL | trait T1 : T2 { - | ^^ note: ...which requires computing the super predicates of `T2`... --> $DIR/issue-12511.rs:5:12 | @@ -22,6 +17,7 @@ LL | / trait T1 : T2 { LL | | LL | | } | |_^ + = 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 previous error diff --git a/tests/ui/dyn-star/param-env-region-infer.next.stderr b/tests/ui/dyn-star/param-env-region-infer.next.stderr index 9ea7677389c..28aec533a00 100644 --- a/tests/ui/dyn-star/param-env-region-infer.next.stderr +++ b/tests/ui/dyn-star/param-env-region-infer.next.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing type of `make_dyn_star::{opaque#0}` LL | fn make_dyn_star<'a, T: PointerLike + Debug + 'a>(t: T) -> impl PointerLike + Debug + 'a { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/param-env-region-infer.rs:16:60 - | -LL | fn make_dyn_star<'a, T: PointerLike + Debug + 'a>(t: T) -> impl PointerLike + Debug + 'a { - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `make_dyn_star`... --> $DIR/param-env-region-infer.rs:16:1 | @@ -28,6 +23,7 @@ LL | | use std::fmt::Debug; LL | | LL | | fn main() {} | |____________^ + = 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 previous error diff --git a/tests/ui/impl-trait/auto-trait-leak.stderr b/tests/ui/impl-trait/auto-trait-leak.stderr index 9c662053c81..a024cff0b8d 100644 --- a/tests/ui/impl-trait/auto-trait-leak.stderr +++ b/tests/ui/impl-trait/auto-trait-leak.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` LL | fn cycle1() -> impl Clone { | ^^^^^^^^^^ | -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 - --> $DIR/auto-trait-leak.rs:11:16 - | -LL | fn cycle1() -> impl Clone { - | ^^^^^^^^^^ note: ...which requires type-checking `cycle1`... --> $DIR/auto-trait-leak.rs:14:5 | @@ -38,6 +33,7 @@ LL | | fn send(_: T) {} LL | | Rc::new(String::from("foo")) LL | | } | |_^ + = 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[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` --> $DIR/auto-trait-leak.rs:11:16 @@ -45,11 +41,6 @@ error[E0391]: cycle detected when computing type of `cycle1::{opaque#0}` LL | fn cycle1() -> impl Clone { | ^^^^^^^^^^ | -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 - --> $DIR/auto-trait-leak.rs:11:16 - | -LL | fn cycle1() -> impl Clone { - | ^^^^^^^^^^ note: ...which requires type-checking `cycle1`... --> $DIR/auto-trait-leak.rs:14:5 | @@ -78,6 +69,7 @@ LL | | fn send(_: T) {} LL | | Rc::new(String::from("foo")) LL | | } | |_^ + = 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: cannot check whether the hidden type of opaque type satisfies auto traits --> $DIR/auto-trait-leak.rs:21:10 diff --git a/tests/ui/infinite/infinite-trait-alias-recursion.stderr b/tests/ui/infinite/infinite-trait-alias-recursion.stderr index 36894dc1894..39d7aa4c16a 100644 --- a/tests/ui/infinite/infinite-trait-alias-recursion.stderr +++ b/tests/ui/infinite/infinite-trait-alias-recursion.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing the super predicates of `T1` LL | trait T1 = T2; | ^^ | -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 - --> $DIR/infinite-trait-alias-recursion.rs:3:12 - | -LL | trait T1 = T2; - | ^^ note: ...which requires computing the super predicates of `T2`... --> $DIR/infinite-trait-alias-recursion.rs:6:12 | @@ -26,6 +21,7 @@ note: cycle used when collecting item types in top-level module | LL | trait T1 = T2; | ^^^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr index 7a4900e5110..bbdb1f70b80 100644 --- a/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr +++ b/tests/ui/infinite/infinite-type-alias-mutual-recursion.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when expanding type alias `X1` 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 - --> $DIR/infinite-type-alias-mutual-recursion.rs:1:11 - | -LL | type X1 = X2; - | ^^ note: ...which requires expanding type alias `X2`... --> $DIR/infinite-type-alias-mutual-recursion.rs:3:11 | @@ -33,6 +28,7 @@ LL | | type X3 = X1; LL | | LL | | fn main() {} | |____________^ + = 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 previous error diff --git a/tests/ui/infinite/infinite-vec-type-recursion.stderr b/tests/ui/infinite/infinite-vec-type-recursion.stderr index 82a53f13f14..a21b033a9a9 100644 --- a/tests/ui/infinite/infinite-vec-type-recursion.stderr +++ b/tests/ui/infinite/infinite-vec-type-recursion.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when expanding type alias `X` LL | type X = Vec; | ^ | -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 - --> $DIR/infinite-vec-type-recursion.rs:1:14 - | -LL | type X = Vec; - | ^ = note: ...which immediately requires expanding type alias `X` again = note: type aliases cannot be recursive = help: consider using a struct, enum, or union instead to break the cycle @@ -21,6 +16,7 @@ LL | | LL | | LL | | fn main() { let b: X = Vec::new(); } | |____________________________________^ + = 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 previous error diff --git a/tests/ui/issues/issue-17252.stderr b/tests/ui/issues/issue-17252.stderr index eaaa6b6dc62..daaf82e80ad 100644 --- a/tests/ui/issues/issue-17252.stderr +++ b/tests/ui/issues/issue-17252.stderr @@ -4,17 +4,13 @@ error[E0391]: cycle detected when const-evaluating + checking `FOO` LL | const FOO: usize = FOO; | ^^^ | -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 - --> $DIR/issue-17252.rs:1:20 - | -LL | const FOO: usize = FOO; - | ^^^ = note: ...which immediately requires const-evaluating + checking `FOO` again note: cycle used when const-evaluating + checking `main::{constant#0}` --> $DIR/issue-17252.rs:4:18 | LL | let _x: [u8; FOO]; // caused stack overflow prior to fix | ^^^ + = 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 previous error diff --git a/tests/ui/issues/issue-20772.stderr b/tests/ui/issues/issue-20772.stderr index 1d51be58954..0c7e728c67e 100644 --- a/tests/ui/issues/issue-20772.stderr +++ b/tests/ui/issues/issue-20772.stderr @@ -4,17 +4,13 @@ error[E0391]: cycle detected when computing the super traits of `T` with associa LL | trait T : Iterator | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/issue-20772.rs:1:1 - | -LL | trait T : Iterator - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: ...which immediately requires computing the super traits of `T` with associated type name `Item` again note: cycle used when computing the super predicates of `T` --> $DIR/issue-20772.rs:1:1 | LL | trait T : Iterator | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/issues/issue-21177.stderr b/tests/ui/issues/issue-21177.stderr index b3e550b36d8..8b749edcc77 100644 --- a/tests/ui/issues/issue-21177.stderr +++ b/tests/ui/issues/issue-21177.stderr @@ -4,17 +4,13 @@ error[E0391]: cycle detected when computing the bounds for type parameter `T` LL | fn foo>() { } | ^^^^ | -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 - --> $DIR/issue-21177.rs:6:21 - | -LL | fn foo>() { } - | ^^^^ = note: ...which immediately requires computing the bounds for type parameter `T` again note: cycle used when computing explicit predicates of `foo` --> $DIR/issue-21177.rs:6:21 | LL | fn foo>() { } | ^^^^ + = 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 previous error diff --git a/tests/ui/issues/issue-23302-1.stderr b/tests/ui/issues/issue-23302-1.stderr index 86773f13511..d807e24403e 100644 --- a/tests/ui/issues/issue-23302-1.stderr +++ b/tests/ui/issues/issue-23302-1.stderr @@ -4,17 +4,13 @@ error[E0391]: cycle detected when const-evaluating + checking `X::A::{constant#0 LL | A = X::A as isize, | ^^^^^^^^^^^^^ | -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 - --> $DIR/issue-23302-1.rs:4:9 - | -LL | A = X::A as isize, - | ^^^^^^^^^^^^^ = note: ...which immediately requires const-evaluating + checking `X::A::{constant#0}` again note: cycle used when simplifying constant for the type system `X::A::{constant#0}` --> $DIR/issue-23302-1.rs:4:9 | LL | A = X::A as isize, | ^^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/issues/issue-23302-2.stderr b/tests/ui/issues/issue-23302-2.stderr index 67d07219d16..91b39dba1ba 100644 --- a/tests/ui/issues/issue-23302-2.stderr +++ b/tests/ui/issues/issue-23302-2.stderr @@ -4,17 +4,13 @@ error[E0391]: cycle detected when const-evaluating + checking `Y::A::{constant#0 LL | A = Y::B as isize, | ^^^^^^^^^^^^^ | -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 - --> $DIR/issue-23302-2.rs:4:9 - | -LL | A = Y::B as isize, - | ^^^^^^^^^^^^^ = note: ...which immediately requires const-evaluating + checking `Y::A::{constant#0}` again note: cycle used when simplifying constant for the type system `Y::A::{constant#0}` --> $DIR/issue-23302-2.rs:4:9 | LL | A = Y::B as isize, | ^^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/issues/issue-23302-3.stderr b/tests/ui/issues/issue-23302-3.stderr index 0cbeee1d079..6b708d81f73 100644 --- a/tests/ui/issues/issue-23302-3.stderr +++ b/tests/ui/issues/issue-23302-3.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when const-evaluating + checking `A` LL | const A: i32 = B; | ^ | -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 - --> $DIR/issue-23302-3.rs:1:16 - | -LL | const A: i32 = B; - | ^ note: ...which requires const-evaluating + checking `B`... --> $DIR/issue-23302-3.rs:3:16 | @@ -20,6 +15,7 @@ note: cycle used when simplifying constant for the type system `A` | LL | const A: i32 = B; | ^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/issues/issue-34373.stderr b/tests/ui/issues/issue-34373.stderr index e2c0c9182bb..0f0821518a4 100644 --- a/tests/ui/issues/issue-34373.stderr +++ b/tests/ui/issues/issue-34373.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing type of `Foo::T` LL | pub struct Foo>>; | ^^^^^^^^^^ | -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 - --> $DIR/issue-34373.rs:7:30 - | -LL | pub struct Foo>>; - | ^^^^^^^^^^ note: ...which requires expanding type alias `DefaultFoo`... --> $DIR/issue-34373.rs:8:19 | @@ -26,6 +21,7 @@ LL | | fn foo(_: T) {} LL | | fn main() { LL | | } | |_^ + = 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 previous error diff --git a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr index cdd4937e724..514bed60700 100644 --- a/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr +++ b/tests/ui/recursion/issue-26548-recursion-via-normalize.stderr @@ -1,10 +1,10 @@ error[E0391]: cycle detected when computing layout of `core::option::Option` | - = 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 = note: ...which requires computing layout of `S`... = note: ...which requires computing layout of `core::option::Option<::It>`... = note: ...which again requires computing layout of `core::option::Option`, completing the cycle = note: cycle used when computing layout of `core::option::Option<::It>` + = 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 previous error diff --git a/tests/ui/recursion/recursive-static-definition.stderr b/tests/ui/recursion/recursive-static-definition.stderr index 85ca99bef45..b112228d403 100644 --- a/tests/ui/recursion/recursive-static-definition.stderr +++ b/tests/ui/recursion/recursive-static-definition.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when const-evaluating + checking `FOO` LL | pub static FOO: u32 = FOO; | ^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/recursive-static-definition.rs:1:1 - | -LL | pub static FOO: u32 = FOO; - | ^^^^^^^^^^^^^^^^^^^ note: ...which requires const-evaluating + checking `FOO`... --> $DIR/recursive-static-definition.rs:1:23 | @@ -23,6 +18,7 @@ LL | | LL | | LL | | fn main() {} | |____________^ + = 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 previous error diff --git a/tests/ui/resolve/resolve-self-in-impl.stderr b/tests/ui/resolve/resolve-self-in-impl.stderr index f9dc44d5b9a..183a17171f7 100644 --- a/tests/ui/resolve/resolve-self-in-impl.stderr +++ b/tests/ui/resolve/resolve-self-in-impl.stderr @@ -44,11 +44,6 @@ error[E0391]: cycle detected when computing trait implemented by ` for S {} | ^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/resolve-self-in-impl.rs:19:1 - | -LL | impl Tr for S {} - | ^^^^^^^^^^^^^^^^^^^^^^ = note: ...which immediately requires computing trait implemented by `` again note: cycle used when collecting item types in top-level module --> $DIR/resolve-self-in-impl.rs:1:1 @@ -61,6 +56,7 @@ LL | | trait Tr { LL | | LL | | fn main() {} | |____________^ + = 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 6 previous errors diff --git a/tests/ui/sized/recursive-type-2.stderr b/tests/ui/sized/recursive-type-2.stderr index 574c0e0021f..0f72f74145e 100644 --- a/tests/ui/sized/recursive-type-2.stderr +++ b/tests/ui/sized/recursive-type-2.stderr @@ -1,6 +1,5 @@ error[E0391]: cycle detected when computing layout of `Foo<()>` | - = 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 = note: ...which requires computing layout of `<() as A>::Assoc`... = note: ...which again requires computing layout of `Foo<()>`, completing the cycle note: cycle used when elaborating drops for `main` @@ -8,6 +7,7 @@ note: cycle used when elaborating drops for `main` | LL | fn main() { | ^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr index af1fa1594ce..62c732fb1d9 100644 --- a/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr +++ b/tests/ui/traits/trait-upcasting/cyclic-trait-resolution.stderr @@ -4,17 +4,13 @@ error[E0391]: cycle detected when computing the super predicates of `A` LL | trait A: B + A {} | ^ | -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 - --> $DIR/cyclic-trait-resolution.rs:1:14 - | -LL | trait A: B + A {} - | ^ = note: ...which immediately requires computing the super predicates of `A` again note: cycle used when collecting item types in top-level module --> $DIR/cyclic-trait-resolution.rs:1:1 | LL | trait A: B + A {} | ^^^^^^^^^^^^^^^^^ + = 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 previous error diff --git a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr index be76d0b2621..aa79b1a57c4 100644 --- a/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr +++ b/tests/ui/type-alias-enum-variants/self-in-enum-definition.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when simplifying constant for the type system `Alph LL | V3 = Self::V1 {} as u8 + 2, | ^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/self-in-enum-definition.rs:5:10 - | -LL | V3 = Self::V1 {} as u8 + 2, - | ^^^^^^^^^^^^^^^^^^^^^ note: ...which requires simplifying constant for the type system `Alpha::V3::{constant#0}`... --> $DIR/self-in-enum-definition.rs:5:10 | @@ -72,6 +67,7 @@ LL | | V2 = Self::V1 as u8 + 1, // OK; See #50072. LL | | LL | | fn main() {} | |____________^ + = 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 previous error diff --git a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr index fb414bca91e..5bd0f76c31f 100644 --- a/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr +++ b/tests/ui/type-alias-impl-trait/auto-trait-leakage3.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` LL | pub type Foo = impl std::fmt::Debug; | ^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/auto-trait-leakage3.rs:7:20 - | -LL | pub type Foo = impl std::fmt::Debug; - | ^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `m::bar`... --> $DIR/auto-trait-leakage3.rs:16:9 | @@ -21,6 +16,7 @@ note: cycle used when checking item types in module `m` | LL | mod m { | ^^^^^ + = 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/auto-trait-leakage3.rs:7:20 @@ -28,11 +24,6 @@ error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` LL | pub type Foo = impl std::fmt::Debug; | ^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/auto-trait-leakage3.rs:7:20 - | -LL | pub type Foo = impl std::fmt::Debug; - | ^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `m::bar`... --> $DIR/auto-trait-leakage3.rs:15:5 | @@ -44,6 +35,7 @@ note: cycle used when checking item types in module `m` | LL | mod m { | ^^^^^ + = 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: cannot check whether the hidden type of `auto_trait_leakage3[211d]::m::Foo::{opaque#0}` satisfies auto traits --> $DIR/auto-trait-leakage3.rs:16:17 diff --git a/tests/ui/type-alias-impl-trait/inference-cycle.stderr b/tests/ui/type-alias-impl-trait/inference-cycle.stderr index 6a14ec8f099..41530dda983 100644 --- a/tests/ui/type-alias-impl-trait/inference-cycle.stderr +++ b/tests/ui/type-alias-impl-trait/inference-cycle.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` LL | pub type Foo = impl std::fmt::Debug; | ^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/inference-cycle.rs:5:20 - | -LL | pub type Foo = impl std::fmt::Debug; - | ^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `m::bar`... --> $DIR/inference-cycle.rs:16:9 | @@ -21,6 +16,7 @@ note: cycle used when checking item types in module `m` | LL | mod m { | ^^^^^ + = 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[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` --> $DIR/inference-cycle.rs:5:20 @@ -28,11 +24,6 @@ error[E0391]: cycle detected when computing type of `m::Foo::{opaque#0}` LL | pub type Foo = impl std::fmt::Debug; | ^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/inference-cycle.rs:5:20 - | -LL | pub type Foo = impl std::fmt::Debug; - | ^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `m::bar`... --> $DIR/inference-cycle.rs:15:5 | @@ -44,6 +35,7 @@ note: cycle used when checking item types in module `m` | LL | mod m { | ^^^^^ + = 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: cannot check whether the hidden type of `inference_cycle[4ecc]::m::Foo::{opaque#0}` satisfies auto traits --> $DIR/inference-cycle.rs:16:17 diff --git a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr index e23b9f3845c..6148131b491 100644 --- a/tests/ui/type-alias-impl-trait/issue-53092-2.stderr +++ b/tests/ui/type-alias-impl-trait/issue-53092-2.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing type of `Bug::{opaque#0}` LL | type Bug = impl Fn(T) -> U + Copy; | ^^^^^^^^^^^^^^^^^^^^^^ | -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 - --> $DIR/issue-53092-2.rs:4:18 - | -LL | type Bug = impl Fn(T) -> U + Copy; - | ^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires type-checking `CONST_BUG`... --> $DIR/issue-53092-2.rs:6:1 | @@ -28,6 +23,7 @@ LL | | type Bug = impl Fn(T) -> U + Copy; LL | | CONST_BUG(0); LL | | } | |_^ + = 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[E0277]: the trait bound `U: From` is not satisfied --> $DIR/issue-53092-2.rs:9:5 diff --git a/tests/ui/type-alias-impl-trait/reveal_local.stderr b/tests/ui/type-alias-impl-trait/reveal_local.stderr index 6c5fe8cf32f..813185c1377 100644 --- a/tests/ui/type-alias-impl-trait/reveal_local.stderr +++ b/tests/ui/type-alias-impl-trait/reveal_local.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when computing type of `Foo::{opaque#0}` LL | type Foo = impl Debug; | ^^^^^^^^^^ | -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 - --> $DIR/reveal_local.rs:5:12 - | -LL | type Foo = impl Debug; - | ^^^^^^^^^^ note: ...which requires type-checking `not_good`... --> $DIR/reveal_local.rs:15:5 | @@ -27,6 +22,7 @@ LL | | LL | | LL | | fn main() {} | |____________^ + = 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[E0391]: cycle detected when computing type of `Foo::{opaque#0}` --> $DIR/reveal_local.rs:5:12 @@ -34,11 +30,6 @@ error[E0391]: cycle detected when computing type of `Foo::{opaque#0}` LL | type Foo = impl Debug; | ^^^^^^^^^^ | -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 - --> $DIR/reveal_local.rs:5:12 - | -LL | type Foo = impl Debug; - | ^^^^^^^^^^ note: ...which requires type-checking `not_good`... --> $DIR/reveal_local.rs:12:1 | @@ -56,6 +47,7 @@ LL | | LL | | LL | | fn main() {} | |____________^ + = 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: cannot check whether the hidden type of `reveal_local[9507]::Foo::{opaque#0}` satisfies auto traits --> $DIR/reveal_local.rs:15:15 @@ -85,11 +77,6 @@ error[E0391]: cycle detected when computing type of `Foo::{opaque#0}` LL | type Foo = impl Debug; | ^^^^^^^^^^ | -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 - --> $DIR/reveal_local.rs:5:12 - | -LL | type Foo = impl Debug; - | ^^^^^^^^^^ note: ...which requires type-checking `not_gooder`... --> $DIR/reveal_local.rs:19:1 | @@ -107,6 +94,7 @@ LL | | LL | | LL | | fn main() {} | |____________^ + = 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: cannot check whether the hidden type of `reveal_local[9507]::Foo::{opaque#0}` satisfies auto traits --> $DIR/reveal_local.rs:25:15 From a903ac5124b8fe8c91b80fe8a6cb16bc784efbd5 Mon Sep 17 00:00:00 2001 From: nxya Date: Wed, 19 Jul 2023 10:02:15 -0400 Subject: [PATCH 7/7] fix issue-110629-private-type-cycle-dyn test --- tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr index 777b4c46798..9aeb3389e2d 100644 --- a/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr +++ b/tests/rustdoc-ui/issue-110629-private-type-cycle-dyn.stderr @@ -4,11 +4,6 @@ error[E0391]: cycle detected when expanding type alias `Bar` LL | type Bar<'a, 'b> = Box>>; | ^^^^^^^^^^^ | -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 - --> $DIR/issue-110629-private-type-cycle-dyn.rs:1:38 - | -LL | type Bar<'a, 'b> = Box>>; - | ^^^^^^^^^^^ = note: ...which immediately requires expanding type alias `Bar` again = note: type aliases cannot be recursive = help: consider using a struct, enum, or union instead to break the cycle @@ -24,6 +19,7 @@ LL | | fn bar<'a, 'b>(i: &'a i32) -> Bar<'a, 'b> { LL | | assert!(bar(&meh) == bar(&muh)); LL | | } | |_^ + = 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 previous error