Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of #106607 - compiler-errors:be-more-accurate-abt-method-s…
…uggestions, r=oli-obk Consider return type when giving various method suggestions 1. Fix a bug in method probe where we weren't normalizing `xform_ret_ty` for non-`impl` method candidates. This shouldn't affect happy-path code, since we only use `xform_ret_ty` when probing methods for diagnostics (I think). 2. Pass the return type expectation down to `lookup_probe`/`probe_for_name` usages in diagnostics. Added a few UI tests to gate against bad suggestions. 3. Make a `FnCtxt::lookup_probe_for_diagnostic` which properly passes down `IsSuggestion(true)`. Should help suppress other weird notes in some corner cases.
- Loading branch information