Crates.io | trust-me-2 |
lib.rs | trust-me-2 |
version | 0.2.0 |
source | src |
created_at | 2024-07-16 22:57:35.520821 |
updated_at | 2024-07-19 18:59:43.848975 |
description | A convenient macro to tell the Rust compiler that you know better and to leave you alone regarding unsafe code. |
homepage | |
repository | https://github.com/fischer36/trust-me-2/ |
max_upload_size | |
id | 1305611 |
size | 3,831 |
An attribute macro that adds an unsafe block around a function body. Inspired by the iconic Trust Me Macro, the additional '2' represents the cutting-edge improvement from pre-existing unsafe macros that still requires a {} block.
cargo add trust-me-2
#[trust_me]
fn secretly_unsafe() {
// Unsafe code
}