rust/compiler
bors 4fa76a4a77 Auto merge of #80828 - SNCPlay42:opaque-projections, r=estebank
Fix expected/found order on impl trait projection mismatch error

fixes #68561

This PR adds a new `ObligationCauseCode` used when checking the concrete type of an impl trait satisfies its bounds, and checks for that cause code in the existing test to see if a projection's normalized type should be the "expected" or "found" type.

The second commit adds a `peel_derives` to that test, which appears to be necessary in some cases (see projection-mismatch-in-impl-where-clause.rs, which would still give expected/found in the wrong order otherwise). This caused some other changes in diagnostics not involving impl trait, but they look correct to me.
2021-04-02 03:39:32 +00:00
..
2021-03-26 09:32:31 -07:00
2021-03-27 22:16:33 -04:00
2021-03-27 22:16:33 -04:00
2021-03-30 20:31:06 +02:00
2021-03-19 19:45:32 -05:00
2021-03-27 22:16:34 -04:00
2021-03-27 22:16:33 -04:00
2021-03-27 22:16:33 -04:00
2021-03-30 20:31:06 +02:00
2021-03-26 09:32:31 -07:00
2021-03-31 10:13:57 -04:00
2021-03-26 09:32:31 -07:00
2021-03-30 20:31:06 +02:00
2021-03-31 10:16:37 -04:00
2021-03-30 20:31:06 +02:00
2021-03-23 17:16:20 +00:00
2021-03-31 10:16:37 -04:00
2021-03-27 22:16:33 -04:00
2021-03-31 10:15:27 -04:00
2021-03-31 10:16:37 -04:00