Undo accidental test deletion in previous commit.

This commit is contained in:
Scott Olson 2016-09-13 20:17:52 -06:00
parent 366c793306
commit 2e70fcdca8

View file

@ -0,0 +1,9 @@
static X: usize = 5;
#[allow(mutable_transmutes)]
fn main() {
unsafe {
*std::mem::transmute::<&usize, &mut usize>(&X) = 6; //~ ERROR: tried to modify constant memory
assert_eq!(X, 6);
}
}