]>
Commit | Line | Data |
---|---|---|
353b0b11 | 1 | // ignore-wasm32 compiled with panic=abort by default |
487cf647 FG |
2 | // unit-test: DataflowConstProp |
3 | ||
4 | #[inline(never)] | |
5 | fn escape<T>(x: &T) {} | |
6 | ||
7 | #[inline(never)] | |
8 | fn some_function() {} | |
9 | ||
10 | // EMIT_MIR ref_without_sb.main.DataflowConstProp.diff | |
11 | fn main() { | |
12 | let mut a = 0; | |
13 | escape(&a); | |
14 | a = 1; | |
15 | some_function(); | |
16 | // This should currently not be propagated. | |
17 | let b = a; | |
18 | } |