Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fn main() {
- let mut num = 1;
- let num_raw_point = &mut num as *mut i32;
- unsafe {
- *num_raw_point = 100;
- println!("{} {} {:p}", num, *num_raw_point, &num); // 100 100 0x8d8c6ff6bc
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement