]> git.lizzy.rs Git - rust.git/blob - src/test/ui/borrowck/borrowck-assignment-to-static-mut.rs
Rollup merge of #102245 - ink-feather-org:const_cmp_by, r=fee1-dead
[rust.git] / src / test / ui / borrowck / borrowck-assignment-to-static-mut.rs
1 // run-pass
2 #![allow(dead_code)]
3 // Test taken from #45641 (https://github.com/rust-lang/rust/issues/45641)
4
5 static mut Y: u32 = 0;
6
7 unsafe fn should_ok() {
8     Y = 1;
9 }
10
11 fn main() {}