Account for unmet T: !Copy in E0277 message

This commit is contained in:
Esteban Küber 2024-02-29 16:30:01 +00:00
parent d89c2c569a
commit 7f97dfe700
2 changed files with 16 additions and 9 deletions

View file

@ -2,7 +2,7 @@ error[E0277]: the trait bound `T: !Copy` is not satisfied
--> $DIR/simple.rs:10:16
|
LL | not_copy::<T>();
| ^ the trait `!Copy` is not implemented for `T`
| ^ the trait bound `T: !Copy` is not satisfied
|
note: required by a bound in `not_copy`
--> $DIR/simple.rs:3:16
@ -14,7 +14,7 @@ error[E0277]: the trait bound `T: !Copy` is not satisfied
--> $DIR/simple.rs:15:16
|
LL | not_copy::<T>();
| ^ the trait `!Copy` is not implemented for `T`
| ^ the trait bound `T: !Copy` is not satisfied
|
note: required by a bound in `not_copy`
--> $DIR/simple.rs:3:16
@ -26,7 +26,7 @@ error[E0277]: the trait bound `Copyable: !Copy` is not satisfied
--> $DIR/simple.rs:30:16
|
LL | not_copy::<Copyable>();
| ^^^^^^^^ the trait `!Copy` is not implemented for `Copyable`
| ^^^^^^^^ the trait bound `Copyable: !Copy` is not satisfied
|
= help: the trait `Copy` is implemented for `Copyable`
note: required by a bound in `not_copy`
@ -44,7 +44,7 @@ error[E0277]: the trait bound `NotNecessarilyCopyable: !Copy` is not satisfied
--> $DIR/simple.rs:37:16
|
LL | not_copy::<NotNecessarilyCopyable>();
| ^^^^^^^^^^^^^^^^^^^^^^ the trait `!Copy` is not implemented for `NotNecessarilyCopyable`
| ^^^^^^^^^^^^^^^^^^^^^^ the trait bound `NotNecessarilyCopyable: !Copy` is not satisfied
|
note: required by a bound in `not_copy`
--> $DIR/simple.rs:3:16