rust/src/test/ui/try-block
Esteban Kuber 3aac307ca6 Mention implementers of unsatisfied trait
When encountering an unsatisfied trait bound, if there are no other
suggestions, mention all the types that *do* implement that trait:

```
error[E0277]: the trait bound `f32: Foo` is not satisfied
  --> $DIR/impl_wf.rs:22:6
   |
LL | impl Baz<f32> for f32 { }
   |      ^^^^^^^^ the trait `Foo` is not implemented for `f32`
   |
   = help: the following other types implement trait `Foo`:
             Option<T>
             i32
             str
note: required by a bound in `Baz`
  --> $DIR/impl_wf.rs:18:31
   |
LL | trait Baz<U: ?Sized> where U: Foo { }
   |                               ^^^ required by this bound in `Baz`
```

Mention implementers of traits in `ImplObligation`s.

Do not mention other `impl`s for closures, ranges and `?`.
2022-04-04 21:01:42 +00:00
..
issue-45124.rs Move some tests to more reasonable directories 2021-11-06 15:35:20 -03:00
try-block-bad-lifetime.rs Run attributes check at crate level 2020-10-03 21:33:47 +02:00
try-block-bad-lifetime.stderr
try-block-bad-type.rs Better rustc_on_unimplemented, and UI test fixes 2021-05-06 11:37:45 -07:00
try-block-bad-type.stderr Mention implementers of unsatisfied trait 2022-04-04 21:01:42 +00:00
try-block-catch.rs
try-block-catch.stderr
try-block-in-edition2015.rs
try-block-in-edition2015.stderr Modify structured suggestion output 2021-08-11 09:46:24 +00:00
try-block-in-match.rs
try-block-in-return.rs
try-block-in-while.rs Better rustc_on_unimplemented, and UI test fixes 2021-05-06 11:37:45 -07:00
try-block-in-while.stderr Do not mention associated items when they introduce an obligation 2021-11-20 19:19:31 +00:00
try-block-maybe-bad-lifetime.rs Run attributes check at crate level 2020-10-03 21:33:47 +02:00
try-block-maybe-bad-lifetime.stderr Fix a format_args span to be expansion 2021-10-29 17:13:15 -05:00
try-block-opt-init.rs
try-block-opt-init.stderr Bless tests 2021-10-15 02:36:58 -05:00
try-block-type-error.rs
try-block-type-error.stderr Better rustc_on_unimplemented, and UI test fixes 2021-05-06 11:37:45 -07:00
try-block-unreachable-code-lint.rs
try-block-unreachable-code-lint.stderr
try-block-unused-delims.fixed
try-block-unused-delims.rs
try-block-unused-delims.stderr Use more accurate spans for "unused delimiter" lint 2021-09-09 14:24:33 +00:00
try-block.rs Move some tests to more suitable subdirs 2021-03-06 18:24:53 +09:00
try-is-identifier-edition2015.rs Move some tests to more reasonable directories 2021-11-18 12:09:34 -03:00