about summary refs log tree commit diff
path: root/compiler/rustc_mir_transform/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2023-10-09 21:03:41 +0000
committerbors <bors@rust-lang.org>2023-10-09 21:03:41 +0000
commit59edd67056919c83c59001a8b4f2d8749359377a (patch)
tree53e0833980837f77efdc461177412d86e929b428 /compiler/rustc_mir_transform/src
parentcdddcd3bea35049dab56888d4391cb9b5b1b4491 (diff)
parent592163fb71a07383141a882d185d80b874490982 (diff)
downloadrust-59edd67056919c83c59001a8b4f2d8749359377a.tar.gz
rust-59edd67056919c83c59001a8b4f2d8749359377a.zip
Auto merge of #116497 - compiler-errors:impl-span, r=cjgillot
Extend `impl`'s `def_span` to include its where clauses

Typically, we highlight the def-span of an impl in a diagnostic due to either:
1. coherence error
2. trait evaluation cycle
3. invalid implementation of built-in trait

I find that an impl's where clauses are very often required to understanding why these errors come about, which is unfortunate since where clauses may be located on different lines and don't show up in the error. This PR expands the def-span of impls to include these where clauses.

r? cjgillot since you've touched this code a while back to make some spans shorter, but you can also reassign to wg-diagnostics or compiler if you're busy or have no strong opinions.
Diffstat (limited to 'compiler/rustc_mir_transform/src')
0 files changed, 0 insertions, 0 deletions