rust/compiler/rustc_mir_dataflow/src
Matthias Krüger 6f8fb911ad
Rollup merge of #98582 - oli-obk:unconstrained_opaque_type, r=estebank
Allow destructuring opaque types in their defining scopes

fixes #96572

Before this PR, the following code snippet failed with an incomprehensible error, and similar code just ICEd in mir borrowck.

```rust
    type T = impl Copy;
    let foo: T = (1u32, 2u32);
    let (a, b) = foo;
```

The problem was that the last line created MIR projections of the form `foo.0` and `foo.1`, but `foo`'s type is `T`, which doesn't have fields (only its hidden type does). But the pattern supplies enough type information (a tuple of two different inference types) to bind a hidden type.
2022-07-16 22:30:47 +02:00
..
framework Rename debugging_opts to unstable_opts 2022-07-13 17:47:06 -05:00
impls Rename debugging_opts to unstable_opts 2022-07-13 17:47:06 -05:00
move_paths Introduce opaque type to hidden type projection 2022-07-15 15:49:22 +00:00
drop_flag_effects.rs Adopt let else in more places 2022-02-19 17:27:43 +01:00
elaborate_drops.rs remove box derefs from codgen 2022-06-15 18:38:26 -07:00
lib.rs add new rval, pull deref early 2022-07-12 14:26:41 +03:00
rustc_peek.rs BitSet perf improvements 2022-06-14 19:41:58 -07:00
storage.rs Remove FIXME from MIR always_storage_live_locals 2022-07-14 15:30:36 -05:00
un_derefer.rs add new rval, pull deref early 2022-07-12 14:26:41 +03:00