rust/compiler/rustc_trait_selection/src
Matthias Krüger af19a50a26
Rollup merge of #94249 - compiler-errors:better-copy-errors, r=davidtwco
Better errors when a Copy impl on a Struct is not self-consistent

As discovered in a Zulip thread with `@nnethercote` and `@Mark-Simulacrum,` it's not immediately obvious why a field on an ADT doesn't implement `Copy`.  This PR attempts to give slightly more detailed information by spinning up a fulfillment context to try to dig down and discover transitive fulfillment errors that cause `is_copy_modulo_regions` to fail on a ADT field.

The error message still kinda sucks, but should only show up in the case that an existing error message was totally missing... so I think it's a good compromise for now?
2022-03-23 22:13:22 +01:00
..
traits Rollup merge of #94249 - compiler-errors:better-copy-errors, r=davidtwco 2022-03-23 22:13:22 +01:00
autoderef.rs Revert "Auto merge of #91491 - spastorino:revert-91354, r=oli-obk" 2021-12-12 12:34:46 +08:00
infer.rs Revert "Auto merge of #91491 - spastorino:revert-91354, r=oli-obk" 2021-12-12 12:34:46 +08:00
lib.rs suggest enabling generic_const_exprs feature if const is unevaluatable 2022-03-09 14:47:50 -08:00
opaque_types.rs Overhaul Const. 2022-02-15 16:19:59 +11:00