diff options
| author | Esteban Küber <esteban@kuber.com.ar> | 2025-08-19 17:49:20 +0000 |
|---|---|---|
| committer | Esteban Küber <esteban@kuber.com.ar> | 2025-08-22 17:55:15 +0000 |
| commit | 049c32797b5f797d5823cdc0e5aaeb0fd68175da (patch) | |
| tree | 1fd5b318305954b5845a8794a33506bd3fa18e73 /tests/ui/span | |
| parent | f5703d5dd3eec176f86a6e9bf7e668b48b84eabb (diff) | |
| download | rust-049c32797b5f797d5823cdc0e5aaeb0fd68175da.tar.gz rust-049c32797b5f797d5823cdc0e5aaeb0fd68175da.zip | |
On E0277, point at type that doesn't implement bound
When encountering an unmet trait bound, point at local type that doesn't implement the trait: ``` error[E0277]: the trait bound `Bar<T>: Foo` is not satisfied --> $DIR/issue-64855.rs:9:19 | LL | pub struct Bar<T>(<Self as Foo>::Type) where Self: ; | ^^^^^^^^^^^^^^^^^^^ unsatisfied trait bound | help: the trait `Foo` is not implemented for `Bar<T>` --> $DIR/issue-64855.rs:9:1 | LL | pub struct Bar<T>(<Self as Foo>::Type) where Self: ; | ^^^^^^^^^^^^^^^^^ ```
Diffstat (limited to 'tests/ui/span')
| -rw-r--r-- | tests/ui/span/issue-71363.stderr | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tests/ui/span/issue-71363.stderr b/tests/ui/span/issue-71363.stderr index 31069914daa..d2f780bdbcb 100644 --- a/tests/ui/span/issue-71363.stderr +++ b/tests/ui/span/issue-71363.stderr @@ -2,8 +2,13 @@ error[E0277]: `MyError` doesn't implement `std::fmt::Display` --> $DIR/issue-71363.rs:4:28 | 4 | impl std::error::Error for MyError {} - | ^^^^^^^ the trait `std::fmt::Display` is not implemented for `MyError` + | ^^^^^^^ unsatisfied trait bound | +help: the trait `std::fmt::Display` is not implemented for `MyError` + --> $DIR/issue-71363.rs:3:1 + | +3 | struct MyError; + | ^^^^^^^^^^^^^^ note: required by a bound in `std::error::Error` --> $SRC_DIR/core/src/error.rs:LL:COL |
