Crates.io | trustme |
lib.rs | trustme |
version | 1.0.1 |
source | src |
created_at | 2023-07-02 07:08:01.499524 |
updated_at | 2023-07-02 07:10:55.777656 |
description | Tell the compiler that you can be trusted to write unsafe code! |
homepage | |
repository | |
max_upload_size | |
id | 905896 |
size | 2,966 |
Tell the compiler that you can be trusted!
use trustme::*;
fn main() {
let mut x: i32 = 0;
let ptr = (&mut x) as *mut i32;
trustme! {*ptr = 42};
println!("{x}");
}