Some docs about pointers recommend addr_of
macros instead of &raw
#133024
Labels
A-docs
Area: Documentation for any part of the project, including the compiler, standard library, and tools
E-easy
Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
Libs-Small
Libs issues that are considered "small" or self-contained
T-libs
Relevant to the library team, which will review and decide on the PR/issue.
Location
Primitive type pointer
core::ptr::read_unaligned
core::ptr::write_unaligned
Summary
The above documentation pages suggest using
ptr::addr_of
andptr::addr_of_mut
respectively, but the pages for those macros recommend using&raw const
and&raw mut
instead.The text was updated successfully, but these errors were encountered: