The back story of this issue is for a non-bug:
Or put a different way.. I have a raw pointer that represents a struct, which somewhere nested down inside, there is another pointer, which points to the root object. I get why in pure rust, this is problematic and how box/pinned/weak etc are there to help.
But in my case, I have C creating the object, so rust will never know that it is self-referential. All it knows, is I have a pointer to raw bytes. When I read in the older rust book (https://doc.rust-lang.org/1.30.0/book/first-edition/raw-pointers.html), it says about pointers:
are plain-old-data, that is, they don't move ownership, again unlike
Box, hence the Rust compiler cannot protect against bugs like use-after-free;
So why would having a *mut pointer in a local block, which is then moved into a struct, EVER be a different pointer to the same memory address (and thus failing equality checks inside of C if I pass the new struct pointer into the C library and it is compared to the original pointer)? why isn't the default behavior not to simply "own" the old pointer?