rust/compiler/rustc_trait_selection/src
bors a707f40107 Auto merge of #95819 - oli-obk:mir_can't_hold_all_these_lifetimes, r=estebank
Enforce Copy bounds for repeat elements while considering lifetimes

fixes https://github.com/rust-lang/rust/issues/95477

this is a breaking change in order to fix a soundness bug.

Before this PR we only checked whether the repeat element type had an `impl Copy`, but not whether that impl also had the appropriate lifetimes. E.g. if the impl was for `YourType<'static>` and not a general `'a`, then copying any type other than a `'static` one should have been rejected, but wasn't.

r? `@lcnr`
2022-04-29 20:00:47 +00:00
..
traits Auto merge of #95819 - oli-obk:mir_can't_hold_all_these_lifetimes, r=estebank 2022-04-29 20:00:47 +00:00
autoderef.rs Filter OnceNote in diagnostic infra. 2022-03-20 20:36:26 +01:00
infer.rs Revert "Auto merge of #91491 - spastorino:revert-91354, r=oli-obk" 2021-12-12 12:34:46 +08:00
lib.rs Stabilize derive_default_enum 2022-04-07 20:03:19 -04:00
opaque_types.rs Spellchecking compiler comments 2022-03-30 15:14:15 -04:00