rust/tests/ui/issues/issue-28776.rs

10 lines
151 B
Rust
Raw Normal View History

// revisions: mir thir
// [thir]compile-flags: -Z thir-unsafeck
use std::ptr;
fn main() {
2016-08-10 07:29:45 +00:00
(&ptr::write)(1 as *mut _, 42);
//~^ ERROR E0133
}