mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-19 12:05:08 +00:00
13 lines
208 B
Rust
13 lines
208 B
Rust
// unit-test: ConstProp
|
|
|
|
static mut STATIC: u32 = 0x42424242;
|
|
|
|
// EMIT_MIR mutable_variable_no_prop.main.ConstProp.diff
|
|
fn main() {
|
|
let mut x = 42;
|
|
unsafe {
|
|
x = STATIC;
|
|
}
|
|
let y = x;
|
|
}
|