summaryrefslogtreecommitdiffstats
path: root/tests/mir-opt/const_prop/read_immutable_static.rs
blob: 0fa18dd101a0b44934819d84e90521a36b88b75f (plain)
1
2
3
4
5
6
7
8
9
10
11
// unit-test: ConstProp

static FOO: u8 = 2;

// EMIT_MIR read_immutable_static.main.ConstProp.diff
fn main() {
    // CHECK-LABEL: fn main(
    // CHECK: debug x => [[x:_.*]];
    // CHECK: [[x]] = const 4_u8;
    let x = FOO + FOO;
}