Installation
Installing Clippy is pretty easy: you will need to install Rust nightly by running rustup toolchain install nightly, then you can install Clippy by running cargo +nightly install clippy.
Note that since Clippy requires a nightly compiler to build, and since it uses compiler intrinsics, some Rust nightly compiler updates make it unusable. Those issues are usually fixed in a couple of days and a new Clippy version gets released, but meanwhile, you can select a previous nightly version by appending a previous date to the nightly toolchain: rustup toolchain install nightly-YYYY-MM-DD.
Once the correct toolchain is installed, Clippy will be installed perfectly. To use it, you will need to go to your project and run cargo clippy instead ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access