rust/compiler/rustc_hir_analysis
bors f361413cbf Auto merge of #106399 - estebank:type-err-span-label, r=nagisa
Modify primary span label for E0308

Looking at the reactions to https://hachyderm.io/`@ekuber/109622160673605438,` a lot of people seem to have trouble understanding the current output, where the primary span label on type errors talks about the specific types that diverged, but these can be deeply nested type parameters. Because of that we could see "expected i32, found u32" in the label while the note said "expected Vec<i32>, found Vec<u32>". This understandably confuses people. I believe that once people learn to read these errors it starts to make more sense, but this PR changes the output to be more in line with what people might expect, without sacrificing terseness.

Fix #68220.
2023-01-31 13:53:40 +00:00
..
src Auto merge of #106399 - estebank:type-err-span-label, r=nagisa 2023-01-31 13:53:40 +00:00
Cargo.toml Rewrite representability 2022-10-07 09:33:46 -05:00
README.md

For high-level intro to how type checking works in rustc, see the type checking chapter of the rustc dev guide.