{
"$type": "site.standard.document",
"bskyPostRef": {
"cid": "bafyreia7jdstw4j2bt6d2qg7xlnh5pbdzd6jzbphb7haohs7wtrsayc5ri",
"uri": "at://did:plc:ivbknywyskln22er3nkssdhl/app.bsky.feed.post/3mm2xlibqb562"
},
"path": "/t/reducing-raw-pointer-footguns-preventing-reference-aliasing-violations-at-compile-time/24301?page=2#post_38",
"publishedAt": "2026-05-17T16:39:13.000Z",
"site": "https://internals.rust-lang.org",
"textContent": "fuji-184:\n\n> But regardless of what you think about it, I need some clear technical feedback,\n\nLet me provide a specific technical claim: `AliasingGuardMut`'s intended property is trivially defeatable. Nothing prevents this, which is the kind of mixing that you want to prevent:\n\n\n let ptr = guard.with_mutable_pointer(|ptr| ptr);\n guard.with_mutable_reference(|r| {\n // do something with `r` and `ptr` here\n });\n\n\nThis means that, if `AliasingGuardMut` provides value, the value will be in the **subjective** realm of “using this type as intended will help people make fewer mistakes”.",
"title": "Reducing Raw Pointer Footguns: Preventing Reference Aliasing Violations at Compile Time"
}