{
"$type": "site.standard.document",
"bskyPostRef": {
"cid": "bafyreiauuyemxk34y6wuyqdjhrv4wbauhryu2jc4v3ejtm7r4lviatubiq",
"uri": "at://did:plc:ivbknywyskln22er3nkssdhl/app.bsky.feed.post/3mlynizpge7u2"
},
"path": "/t/reducing-raw-pointer-footguns-preventing-reference-aliasing-violations-at-compile-time/24301?page=2#post_22",
"publishedAt": "2026-05-16T09:41:19.000Z",
"site": "https://internals.rust-lang.org",
"textContent": "The example gives compile time error. Did you run with the code in the opening post? The newest code is in the reply. I will put it in the opening post\n\nWhere 1 one the example is indeed invalidate the head. That is because I didn't wrap the head pointer with the guard. After I wrap all will guard, it now prevents the head pointer invalidation",
"title": "Reducing Raw Pointer Footguns: Preventing Reference Aliasing Violations at Compile Time"
}