Skip to content

Commit 9d131f6

Browse files
committed
Fix tests
1 parent a336145 commit 9d131f6

8 files changed

+16
-8
lines changed

src/test/compile-fail/issue-20413.rs

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ struct NoData<T>;
1818
impl<T> Foo for T where NoData<T>: Foo {
1919
//~^ ERROR: overflow evaluating the requirement
2020
fn answer(self) {
21+
//~^ ERROR: overflow evaluating the requirement
2122
let val: NoData<T> = NoData;
2223
}
2324
}

src/test/compile-fail/issue-21946.rs

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ struct FooStruct;
1717
impl Foo for FooStruct {
1818
//~^ ERROR overflow evaluating the requirement `<FooStruct as Foo>::A`
1919
type A = <FooStruct as Foo>::A;
20+
//~^ ERROR overflow evaluating the requirement `<FooStruct as Foo>::A`
2021
}
2122

2223
fn main() {}

src/test/compile-fail/issue-23122-1.rs

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ struct GetNext<T: Next> { t: T }
1717
impl<T: Next> Next for GetNext<T> {
1818
//~^ ERROR overflow evaluating the requirement
1919
type Next = <GetNext<T> as Next>::Next;
20+
//~^ ERROR overflow evaluating the requirement
2021
}
2122

2223
fn main() {}

src/test/compile-fail/issue-23122-2.rs

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ struct GetNext<T: Next> { t: T }
1717
impl<T: Next> Next for GetNext<T> {
1818
//~^ ERROR overflow evaluating the requirement
1919
type Next = <GetNext<T::Next> as Next>::Next;
20+
//~^ ERROR overflow evaluating the requirement
2021
}
2122

2223
fn main() {}

src/test/ui/cycle-trait-supertrait-indirect.stderr

-5
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,6 @@ note: ...which requires computing the supertraits of `C`...
1010
LL | trait C: B { }
1111
| ^^^^^^^^^^
1212
= note: ...which again requires computing the supertraits of `B`, completing the cycle
13-
note: cycle used when computing the supertraits of `A`
14-
--> $DIR/cycle-trait-supertrait-indirect.rs:14:1
15-
|
16-
LL | trait A: B {
17-
| ^^^^^^^^^^
1813

1914
error: aborting due to previous error
2015

src/test/ui/impl-trait/auto-trait-leak.stderr

-1
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,6 @@ note: ...which requires processing `cycle1::{{impl-Trait}}`...
5252
LL | fn cycle1() -> impl Clone {
5353
| ^^^^^^^^^^
5454
= note: ...which again requires processing `cycle1`, completing the cycle
55-
note: cycle used when type-checking all item bodies
5655

5756
error: aborting due to 3 previous errors
5857

src/test/ui/span/issue-35987.rs

+1
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ impl<T: Clone, Add> Add for Foo<T> {
1717
type Output = usize;
1818

1919
fn add(self, rhs: Self) -> Self::Output {
20+
//~^ ERROR ambiguous associated type
2021
unimplemented!();
2122
}
2223
}

src/test/ui/span/issue-35987.stderr

+11-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,15 @@ help: possible better candidate is found in another module, you can import it in
88
LL | use std::ops::Add;
99
|
1010

11-
error: aborting due to previous error
11+
error[E0223]: ambiguous associated type
12+
--> $DIR/issue-35987.rs:19:32
13+
|
14+
LL | fn add(self, rhs: Self) -> Self::Output {
15+
| ^^^^^^^^^^^^ ambiguous associated type
16+
|
17+
= note: specify the type using the syntax `<Foo<T> as Trait>::Output`
18+
19+
error: aborting due to 2 previous errors
1220

13-
For more information about this error, try `rustc --explain E0404`.
21+
Some errors occurred: E0223, E0404.
22+
For more information about an error, try `rustc --explain E0223`.

0 commit comments

Comments
 (0)