Crates.io | raw_pointer |
lib.rs | raw_pointer |
version | 0.1.4 |
source | src |
created_at | 2021-05-25 00:08:16.631329 |
updated_at | 2021-06-10 14:48:41.172277 |
description | Safely handling raw mutable pointers to a generic type |
homepage | |
repository | https://github.com/JIceberg/raw-pointer |
max_upload_size | |
id | 401617 |
size | 4,882 |
Allows for safely handling raw, mutable pointers to a generic type in Rust.
let mut val: u32 = 6;
let mut ptr_val = Pointer::<u32>::new(&mut val);
*ptr_val = 9;
let mut temp_tegister: Pointer<MyRegister> = Pointer::<MyRegister>::from(0xFFFF0000);
test_and_set(temp_register.value);