diff --git a/src/test/ui/cycle-trait/cycle-trait-default-type-trait.stderr b/src/test/ui/cycle-trait/cycle-trait-default-type-trait.stderr index 1a75eb5e31450..aa45462a52e41 100644 --- a/src/test/ui/cycle-trait/cycle-trait-default-type-trait.stderr +++ b/src/test/ui/cycle-trait/cycle-trait-default-type-trait.stderr @@ -5,6 +5,11 @@ LL | trait Foo> { | ^^^ | = note: ...which again requires processing `Foo::X`, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/cycle-trait-default-type-trait.rs:4:1 + | +LL | trait Foo> { + | ^^^^^^^^^^^^^^^^^^^^^^^ error: aborting due to previous error diff --git a/src/test/ui/cycle-trait/cycle-trait-supertrait-direct.stderr b/src/test/ui/cycle-trait/cycle-trait-supertrait-direct.stderr index 22efa8ee0a58d..8aa3ac8abf52c 100644 --- a/src/test/ui/cycle-trait/cycle-trait-supertrait-direct.stderr +++ b/src/test/ui/cycle-trait/cycle-trait-supertrait-direct.stderr @@ -5,6 +5,11 @@ LL | trait Chromosome: Chromosome { | ^^^^^^^^^^ | = note: ...which again requires computing the supertraits of `Chromosome`, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/cycle-trait-supertrait-direct.rs:3:1 + | +LL | trait Chromosome: Chromosome { + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: aborting due to previous error diff --git a/src/test/ui/existential_types/no_inferrable_concrete_type.stderr b/src/test/ui/existential_types/no_inferrable_concrete_type.stderr index 9d2609e546db5..fab61bd9ed065 100644 --- a/src/test/ui/existential_types/no_inferrable_concrete_type.stderr +++ b/src/test/ui/existential_types/no_inferrable_concrete_type.stderr @@ -10,6 +10,17 @@ note: ...which requires processing `bar`... LL | fn bar(x: Foo) -> Foo { x } | ^^^^^ = note: ...which again requires processing `Foo`, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/no_inferrable_concrete_type.rs:4:1 + | +LL | / #![feature(existential_type)] +LL | | +LL | | existential type Foo: Copy; //~ cycle detected +LL | | +... | +LL | | let _: Foo = std::mem::transmute(0u8); +LL | | } + | |_^ error: aborting due to previous error diff --git a/src/test/ui/impl-trait/auto-trait-leak.stderr b/src/test/ui/impl-trait/auto-trait-leak.stderr index d6928584b9e43..4acc400f8e799 100644 --- a/src/test/ui/impl-trait/auto-trait-leak.stderr +++ b/src/test/ui/impl-trait/auto-trait-leak.stderr @@ -22,6 +22,17 @@ LL | fn cycle2() -> impl Clone { | ^^^^^^^^^^^^^^^^^^^^^^^^^ note: ...which requires evaluating trait selection obligation `impl std::clone::Clone: std::marker::Send`... = note: ...which again requires processing `cycle1::{{impl-Trait}}`, completing the cycle +note: cycle used when checking item types in top-level module + --> $DIR/auto-trait-leak.rs:3:1 + | +LL | / use std::cell::Cell; +LL | | use std::rc::Rc; +LL | | +LL | | fn send(_: T) {} +... | +LL | | Rc::new(String::from("foo")) +LL | | } + | |_^ error[E0391]: cycle detected when processing `cycle1::{{impl-Trait}}` --> $DIR/auto-trait-leak.rs:14:16 @@ -46,6 +57,17 @@ note: ...which requires processing `cycle2`... LL | fn cycle2() -> impl Clone { | ^^^^^^^^^^^^^^^^^^^^^^^^^ = note: ...which again requires processing `cycle1::{{impl-Trait}}`, completing the cycle +note: cycle used when checking item types in top-level module + --> $DIR/auto-trait-leak.rs:3:1 + | +LL | / use std::cell::Cell; +LL | | use std::rc::Rc; +LL | | +LL | | fn send(_: T) {} +... | +LL | | Rc::new(String::from("foo")) +LL | | } + | |_^ error[E0277]: `std::rc::Rc` cannot be sent between threads safely --> $DIR/auto-trait-leak.rs:17:5 diff --git a/src/test/ui/infinite/infinite-vec-type-recursion.stderr b/src/test/ui/infinite/infinite-vec-type-recursion.stderr index eb1461a7b29e1..daa18a7e9b1ce 100644 --- a/src/test/ui/infinite/infinite-vec-type-recursion.stderr +++ b/src/test/ui/infinite/infinite-vec-type-recursion.stderr @@ -5,6 +5,14 @@ LL | type X = Vec; | ^ | = note: ...which again requires processing `X`, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/infinite-vec-type-recursion.rs:1:1 + | +LL | / type X = Vec; +LL | | //~^ ERROR cycle detected +LL | | +LL | | fn main() { let b: X = Vec::new(); } + | |____________________________________^ error: aborting due to previous error diff --git a/src/test/ui/issues/issue-12511.stderr b/src/test/ui/issues/issue-12511.stderr index 945cdc745efb0..37e38ff60ae4b 100644 --- a/src/test/ui/issues/issue-12511.stderr +++ b/src/test/ui/issues/issue-12511.stderr @@ -10,6 +10,11 @@ note: ...which requires computing the supertraits of `T2`... LL | trait T2 : T1 { | ^^ = note: ...which again requires computing the supertraits of `T1`, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/issue-12511.rs:1:1 + | +LL | trait T1 : T2 { + | ^^^^^^^^^^^^^ error: aborting due to previous error diff --git a/src/test/ui/issues/issue-20772.stderr b/src/test/ui/issues/issue-20772.stderr index 15a5fc40926fe..7dc4e43fd573d 100644 --- a/src/test/ui/issues/issue-20772.stderr +++ b/src/test/ui/issues/issue-20772.stderr @@ -8,6 +8,14 @@ LL | | {} | |__^ | = note: ...which again requires computing the supertraits of `T`, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/issue-20772.rs:1:1 + | +LL | / trait T : Iterator +LL | | //~^ ERROR cycle detected +LL | | //~| ERROR associated type `Item` not found for `Self` +LL | | {} + | |__^ error[E0220]: associated type `Item` not found for `Self` --> $DIR/issue-20772.rs:1:25 diff --git a/src/test/ui/issues/issue-20825.stderr b/src/test/ui/issues/issue-20825.stderr index 1df51dc2d41ac..5f9709d1c649b 100644 --- a/src/test/ui/issues/issue-20825.stderr +++ b/src/test/ui/issues/issue-20825.stderr @@ -5,6 +5,11 @@ LL | pub trait Processor: Subscriber { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = note: ...which again requires computing the supertraits of `Processor`, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/issue-20825.rs:5:1 + | +LL | pub trait Processor: Subscriber { + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: aborting due to previous error diff --git a/src/test/ui/issues/issue-22673.stderr b/src/test/ui/issues/issue-22673.stderr index 4b5730c91eb55..9e7e4b218b1c6 100644 --- a/src/test/ui/issues/issue-22673.stderr +++ b/src/test/ui/issues/issue-22673.stderr @@ -5,6 +5,11 @@ LL | trait Expr : PartialEq { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = note: ...which again requires computing the supertraits of `Expr`, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/issue-22673.rs:1:1 + | +LL | trait Expr : PartialEq { + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: aborting due to previous error diff --git a/src/test/ui/issues/issue-34373.stderr b/src/test/ui/issues/issue-34373.stderr index 45e8d1bf3e399..07ac421455cf6 100644 --- a/src/test/ui/issues/issue-34373.stderr +++ b/src/test/ui/issues/issue-34373.stderr @@ -10,6 +10,17 @@ note: ...which requires processing `DefaultFoo`... LL | type DefaultFoo = Foo; | ^^^ = note: ...which again requires processing `Foo::T`, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/issue-34373.rs:1:1 + | +LL | / #![allow(warnings)] +LL | | +LL | | trait Trait { +LL | | fn foo(_: T) {} +... | +LL | | fn main() { +LL | | } + | |_^ error: aborting due to previous error diff --git a/src/test/ui/resolve/issue-23305.stderr b/src/test/ui/resolve/issue-23305.stderr index 17b2f9fa4fbbc..1da56ad05d28c 100644 --- a/src/test/ui/resolve/issue-23305.stderr +++ b/src/test/ui/resolve/issue-23305.stderr @@ -5,6 +5,11 @@ LL | impl ToNbt {} | ^^^^ | = note: ...which again requires processing ``, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/issue-23305.rs:1:1 + | +LL | pub trait ToNbt { + | ^^^^^^^^^^^^^^^^^^ error: aborting due to previous error diff --git a/src/test/ui/resolve/resolve-self-in-impl.stderr b/src/test/ui/resolve/resolve-self-in-impl.stderr index 47704f114d16c..1940c0cd2a4b7 100644 --- a/src/test/ui/resolve/resolve-self-in-impl.stderr +++ b/src/test/ui/resolve/resolve-self-in-impl.stderr @@ -5,6 +5,17 @@ LL | impl Tr for Self {} //~ ERROR cycle detected | ^^^^ | = note: ...which again requires processing ``, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/resolve-self-in-impl.rs:1:1 + | +LL | / #![feature(associated_type_defaults)] +LL | | +LL | | struct S(T); +LL | | trait Tr { +... | +LL | | +LL | | fn main() {} + | |____________^ error[E0391]: cycle detected when processing `` --> $DIR/resolve-self-in-impl.rs:15:15 @@ -13,6 +24,17 @@ LL | impl Tr for S {} //~ ERROR cycle detected | ^^^^ | = note: ...which again requires processing ``, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/resolve-self-in-impl.rs:1:1 + | +LL | / #![feature(associated_type_defaults)] +LL | | +LL | | struct S(T); +LL | | trait Tr { +... | +LL | | +LL | | fn main() {} + | |____________^ error[E0391]: cycle detected when processing `` --> $DIR/resolve-self-in-impl.rs:16:6 @@ -21,6 +43,17 @@ LL | impl Self {} //~ ERROR cycle detected | ^^^^ | = note: ...which again requires processing ``, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/resolve-self-in-impl.rs:1:1 + | +LL | / #![feature(associated_type_defaults)] +LL | | +LL | | struct S(T); +LL | | trait Tr { +... | +LL | | +LL | | fn main() {} + | |____________^ error[E0391]: cycle detected when processing `` --> $DIR/resolve-self-in-impl.rs:17:8 @@ -29,6 +62,17 @@ LL | impl S {} //~ ERROR cycle detected | ^^^^ | = note: ...which again requires processing ``, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/resolve-self-in-impl.rs:1:1 + | +LL | / #![feature(associated_type_defaults)] +LL | | +LL | | struct S(T); +LL | | trait Tr { +... | +LL | | +LL | | fn main() {} + | |____________^ error[E0391]: cycle detected when processing `` --> $DIR/resolve-self-in-impl.rs:18:1 @@ -37,6 +81,17 @@ LL | impl Tr for S {} //~ ERROR cycle detected | ^^^^^^^^^^^^^^^^^^^^^^ | = note: ...which again requires processing ``, completing the cycle +note: cycle used when collecting item types in top-level module + --> $DIR/resolve-self-in-impl.rs:1:1 + | +LL | / #![feature(associated_type_defaults)] +LL | | +LL | | struct S(T); +LL | | trait Tr { +... | +LL | | +LL | | fn main() {} + | |____________^ error: aborting due to 5 previous errors diff --git a/src/test/ui/simd-intrinsic/simd-intrinsic-declaration-type.stderr b/src/test/ui/simd-intrinsic/simd-intrinsic-declaration-type.stderr index 4c1985b9f3af1..22df5e42d2607 100644 --- a/src/test/ui/simd-intrinsic/simd-intrinsic-declaration-type.stderr +++ b/src/test/ui/simd-intrinsic/simd-intrinsic-declaration-type.stderr @@ -1,39 +1,3 @@ -error[E0442]: intrinsic argument 1 has wrong type: found `u16`, expected `i16` - --> $DIR/simd-intrinsic-declaration-type.rs:33:9 - | -LL | fn x86_mm_adds_epi16(x: u16x8, y: u16x8) -> u16x8; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -error[E0442]: intrinsic argument 2 has wrong type: found `u16`, expected `i16` - --> $DIR/simd-intrinsic-declaration-type.rs:33:9 - | -LL | fn x86_mm_adds_epi16(x: u16x8, y: u16x8) -> u16x8; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -error[E0442]: intrinsic return value has wrong type: found `u16`, expected `i16` - --> $DIR/simd-intrinsic-declaration-type.rs:33:9 - | -LL | fn x86_mm_adds_epi16(x: u16x8, y: u16x8) -> u16x8; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -error[E0442]: intrinsic argument 1 has wrong type: found `i16`, expected `u16` - --> $DIR/simd-intrinsic-declaration-type.rs:37:9 - | -LL | fn x86_mm_adds_epu16(x: i16x8, y: i16x8) -> i16x8; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -error[E0442]: intrinsic argument 2 has wrong type: found `i16`, expected `u16` - --> $DIR/simd-intrinsic-declaration-type.rs:37:9 - | -LL | fn x86_mm_adds_epu16(x: i16x8, y: i16x8) -> i16x8; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -error[E0442]: intrinsic return value has wrong type: found `i16`, expected `u16` - --> $DIR/simd-intrinsic-declaration-type.rs:37:9 - | -LL | fn x86_mm_adds_epu16(x: i16x8, y: i16x8) -> i16x8; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - error[E0442]: intrinsic argument 1 has wrong type: found vector with length 16, expected length 8 --> $DIR/simd-intrinsic-declaration-type.rs:45:5 | @@ -70,6 +34,42 @@ error[E0442]: intrinsic return value has wrong type: found `i32`, expected `f32` LL | fn x86_mm_max_ps(x: i32x4, y: i32x4) -> i32x4; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ +error[E0442]: intrinsic argument 1 has wrong type: found `u16`, expected `i16` + --> $DIR/simd-intrinsic-declaration-type.rs:33:9 + | +LL | fn x86_mm_adds_epi16(x: u16x8, y: u16x8) -> u16x8; + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +error[E0442]: intrinsic argument 2 has wrong type: found `u16`, expected `i16` + --> $DIR/simd-intrinsic-declaration-type.rs:33:9 + | +LL | fn x86_mm_adds_epi16(x: u16x8, y: u16x8) -> u16x8; + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +error[E0442]: intrinsic return value has wrong type: found `u16`, expected `i16` + --> $DIR/simd-intrinsic-declaration-type.rs:33:9 + | +LL | fn x86_mm_adds_epi16(x: u16x8, y: u16x8) -> u16x8; + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +error[E0442]: intrinsic argument 1 has wrong type: found `i16`, expected `u16` + --> $DIR/simd-intrinsic-declaration-type.rs:37:9 + | +LL | fn x86_mm_adds_epu16(x: i16x8, y: i16x8) -> i16x8; + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +error[E0442]: intrinsic argument 2 has wrong type: found `i16`, expected `u16` + --> $DIR/simd-intrinsic-declaration-type.rs:37:9 + | +LL | fn x86_mm_adds_epu16(x: i16x8, y: i16x8) -> i16x8; + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +error[E0442]: intrinsic return value has wrong type: found `i16`, expected `u16` + --> $DIR/simd-intrinsic-declaration-type.rs:37:9 + | +LL | fn x86_mm_adds_epu16(x: i16x8, y: i16x8) -> i16x8; + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + error: aborting due to 12 previous errors For more information about this error, try `rustc --explain E0442`.