mirror of
https://github.com/rust-lang/rust.git
synced 2025-01-06 21:07:00 +00:00
c56c7e2d02
New lint: suggest `ptr::read` instead of `mem::replace(..., uninitialized())` resolves: #5575 changelog: improvements to `MEM_REPLACE_WITH_UNINIT`: - add a new test case in `tests/ui/repl_uninit.rs` to cover the case of replacing with `mem::MaybeUninit::uninit().assume_init()`. - modify the existing `MEM_REPLACE_WITH_UNINIT` when replacing with `mem::uninitialized` to suggest using `ptr::read` instead. - lint with `MEM_REPLACE_WITH_UNINIT` when replacing with `mem::MaybeUninit::uninit().assume_init()` |
||
---|---|---|
.. | ||
src | ||
Cargo.toml | ||
README.md |