blob: 87ef00d18295fe1ca861d419d1f9f2b5004ad43e (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
// unit-test: DataflowConstProp
// EMIT_MIR sibling_ptr.main.DataflowConstProp.diff
fn main() {
let mut x: (u8, u8) = (0, 0);
unsafe {
let p = std::ptr::addr_of_mut!(x.0);
*p.add(1) = 1;
}
let x1 = x.1; // should not be propagated
}
|