You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Rollup merge of rust-lang#46462 - sinkuu:copyprop_reg2, r=arielb1
Fix CopyPropagation regression (2)
Remaining part of MIR copyprop regression by (I think) rust-lang#45380, which I missed in rust-lang#45753.
```rust
fn foo(mut x: i32) -> i32 {
let y = x;
x = 123; // `x` is assigned only once in MIR, but cannot be propagated to `y`
y
}
```
So any assignment to an argument cannot be propagated.
0 commit comments