Skip to content

Commit

Permalink
Rollup merge of #129653 - RalfJung:addr-of-read-only, r=scottmcm
Browse files Browse the repository at this point in the history
clarify that addr_of creates read-only pointers

Stacked Borrows does make this UB, but Tree Borrows does not. This is tied up with rust-lang/rust#56604 and other UCG discussions. Also see [this collection of links](Rust-for-Linux/linux#950 (comment)) where rustc treats `addr_of!` as a "non-mutating use".

So, let's better be careful for now.
  • Loading branch information
matthiaskrgr authored Sep 5, 2024
2 parents 97ae114 + 3dfff01 commit 7cec2c9
Showing 0 changed files with 0 additions and 0 deletions.

0 comments on commit 7cec2c9

Please sign in to comment.