]> git.lizzy.rs Git - rust.git/blob - tests/mir-opt/copy-prop/dead_stores_79191.rs
Auto merge of #107443 - cjgillot:generator-less-query, r=compiler-errors
[rust.git] / tests / mir-opt / copy-prop / dead_stores_79191.rs
1 // unit-test: CopyProp
2
3 fn id<T>(x: T) -> T {
4     x
5 }
6
7 // EMIT_MIR dead_stores_79191.f.CopyProp.after.mir
8 fn f(mut a: usize) -> usize {
9     let b = a;
10     a = 5;
11     a = b;
12     id(a)
13 }
14
15 fn main() {
16     f(0);
17 }