rust/tests/mir-opt/dataflow-const-prop/self_assign_add.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

16 lines
285 B
Rust
Raw Normal View History

//@ test-mir-pass: DataflowConstProp
// EMIT_MIR self_assign_add.main.DataflowConstProp.diff
2024-01-12 01:22:33 -06:00
// CHECK-LABEL: fn main(
fn main() {
// CHECK: debug a => [[a:_.*]];
let mut a = 0;
// CHECK: [[a]] = const 1_i32;
a += 1;
// CHECK: [[a]] = const 2_i32;
a += 1;
}