You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I now believe that the current implementation of partial_ref runs into undefined behavior. It uses temporary references to construct raw pointer-to-field values, those temporary references can alias in a way that is not allowed. AFAICT this works in practice and is done in many other crates as there currently is no other way to do this in stable rust.
There is an accepted RFC rust-lang/rfcs#2582 that would allow to do this properly.
Make sure that the way raw pointers are used to implement this crate makes it impossible to violate the stacked borrows model using the safe API.
The text was updated successfully, but these errors were encountered: