Skip to content

Commit be70e89

Browse files
committed
rebase + fix CI
1 parent 5c51396 commit be70e89

File tree

2 files changed

+9
-18
lines changed

2 files changed

+9
-18
lines changed

tests/ui/impl-trait/issues/issue-62742.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ fn _alias_check() {
44
WrongImpl::foo(0i32);
55
//~^ ERROR the trait bound `RawImpl<_>: Raw<_>` is not satisfied
66
//~| ERROR the trait bound `RawImpl<_>: Raw<_>` is not satisfied
7-
//~| ERROR the trait bound `RawImpl<_>: Raw<_>` is not satisfied
87
WrongImpl::<()>::foo(0i32);
98
//~^ ERROR the trait bound `RawImpl<()>: Raw<()>` is not satisfied
109
//~| ERROR trait bounds were not satisfied

tests/ui/impl-trait/issues/issue-62742.stderr

Lines changed: 9 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@ error[E0277]: the trait bound `RawImpl<_>: Raw<_>` is not satisfied
22
--> $DIR/issue-62742.rs:4:5
33
|
44
LL | WrongImpl::foo(0i32);
5-
| ^^^^^^^^^^^^^^ the trait `Raw<_>` is not implemented for `RawImpl<_>`
5+
| ^^^^^^^^^^^^^^^^^^^^ the trait `Raw<_>` is not implemented for `RawImpl<_>`
66
|
77
= help: the trait `Raw<[_]>` is implemented for `RawImpl<_>`
88
note: required by a bound in `SafeImpl::<T, A>::foo`
9-
--> $DIR/issue-62742.rs:30:20
9+
--> $DIR/issue-62742.rs:29:20
1010
|
1111
LL | impl<T: ?Sized, A: Raw<T>> SafeImpl<T, A> {
1212
| ^^^^^^ required by this bound in `SafeImpl::<T, A>::foo`
@@ -21,21 +21,13 @@ LL | WrongImpl::foo(0i32);
2121
|
2222
= help: the trait `Raw<[_]>` is implemented for `RawImpl<_>`
2323
note: required by a bound in `SafeImpl`
24-
--> $DIR/issue-62742.rs:28:35
24+
--> $DIR/issue-62742.rs:27:35
2525
|
2626
LL | pub struct SafeImpl<T: ?Sized, A: Raw<T>>(PhantomData<(A, T)>);
2727
| ^^^^^^ required by this bound in `SafeImpl`
2828

29-
error[E0277]: the trait bound `RawImpl<_>: Raw<_>` is not satisfied
30-
--> $DIR/issue-62742.rs:4:5
31-
|
32-
LL | WrongImpl::foo(0i32);
33-
| ^^^^^^^^^^^^^^^^^^^^ the trait `Raw<_>` is not implemented for `RawImpl<_>`
34-
|
35-
= help: the trait `Raw<[_]>` is implemented for `RawImpl<_>`
36-
3729
error[E0599]: the function or associated item `foo` exists for struct `SafeImpl<(), RawImpl<()>>`, but its trait bounds were not satisfied
38-
--> $DIR/issue-62742.rs:8:22
30+
--> $DIR/issue-62742.rs:7:22
3931
|
4032
LL | WrongImpl::<()>::foo(0i32);
4133
| ^^^ function or associated item cannot be called on `SafeImpl<(), RawImpl<()>>` due to unsatisfied trait bounds
@@ -47,33 +39,33 @@ LL | pub struct SafeImpl<T: ?Sized, A: Raw<T>>(PhantomData<(A, T)>);
4739
| ----------------------------------------- function or associated item `foo` not found for this struct
4840
|
4941
note: trait bound `RawImpl<()>: Raw<()>` was not satisfied
50-
--> $DIR/issue-62742.rs:30:20
42+
--> $DIR/issue-62742.rs:29:20
5143
|
5244
LL | impl<T: ?Sized, A: Raw<T>> SafeImpl<T, A> {
5345
| ^^^^^^ --------------
5446
| |
5547
| unsatisfied trait bound introduced here
5648
note: the trait `Raw` must be implemented
57-
--> $DIR/issue-62742.rs:14:1
49+
--> $DIR/issue-62742.rs:13:1
5850
|
5951
LL | pub trait Raw<T: ?Sized> {
6052
| ^^^^^^^^^^^^^^^^^^^^^^^^
6153

6254
error[E0277]: the trait bound `RawImpl<()>: Raw<()>` is not satisfied
63-
--> $DIR/issue-62742.rs:8:5
55+
--> $DIR/issue-62742.rs:7:5
6456
|
6557
LL | WrongImpl::<()>::foo(0i32);
6658
| ^^^^^^^^^^^^^^^ the trait `Raw<()>` is not implemented for `RawImpl<()>`
6759
|
6860
= help: the trait `Raw<[()]>` is implemented for `RawImpl<()>`
6961
= help: for that trait implementation, expected `[()]`, found `()`
7062
note: required by a bound in `SafeImpl`
71-
--> $DIR/issue-62742.rs:28:35
63+
--> $DIR/issue-62742.rs:27:35
7264
|
7365
LL | pub struct SafeImpl<T: ?Sized, A: Raw<T>>(PhantomData<(A, T)>);
7466
| ^^^^^^ required by this bound in `SafeImpl`
7567

76-
error: aborting due to 5 previous errors
68+
error: aborting due to 4 previous errors
7769

7870
Some errors have detailed explanations: E0277, E0599.
7971
For more information about an error, try `rustc --explain E0277`.

0 commit comments

Comments
 (0)