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
Copy file name to clipboardExpand all lines: clippy_lints/src/casts/mod.rs
+6-4Lines changed: 6 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -228,10 +228,12 @@ declare_clippy_lint! {
228
228
/// Dereferencing the resulting pointer may be undefined behavior.
229
229
///
230
230
/// ### Known problems
231
-
/// Using [`std::ptr::read_unaligned`](https://doc.rust-lang.org/std/ptr/fn.read_unaligned.html) and [`std::ptr::write_unaligned`](https://doc.rust-lang.org/std/ptr/fn.write_unaligned.html) or
232
-
/// similar on the resulting pointer is fine. Is over-zealous: casts with
233
-
/// manual alignment checks or casts like `u64` -> `u8` -> `u16` can be
234
-
/// fine. Miri is able to do a more in-depth analysis.
231
+
/// Using [`std::ptr::read_unaligned`](https://doc.rust-lang.org/std/ptr/fn.read_unaligned.html)
232
+
/// and [`std::ptr::write_unaligned`](https://doc.rust-lang.org/std/ptr/fn.write_unaligned.html)
233
+
/// or similar on the resulting pointer is fine.
234
+
///
235
+
/// Is over-zealous: casts with manual alignment checks or casts like `u64` -> `u8` -> `u16` can be fine.
0 commit comments