github.com/rust-lang/rust-clippy

A bunch of lints to catch common mistakes and improve your Rust code. Book: https://doc.rust-lang.org/clippy/

Open this visualization on its own page →

Contributors

557

Lines of Code

34,208

From

2014-11-19

To

2020-12-22

About rust-lang/rust-clippy

Clippy is a collection of over 800 lints for the Rust programming language designed to catch common mistakes and encourage idiomatic code. The lints are organized into categories with configurable severity levels, ranging from strict correctness checks to optional pedantic suggestions. By default, Clippy enables lints across correctness, suspicious code patterns, style, complexity, and performance—with correctness-related warnings set to deny level to prevent outright bugs. Users can customize which lints apply to their projects through code attributes, command-line flags, or a `clippy.toml` configuration file.

Clippy integrates directly into Rust's build toolchain as a cargo subcommand and can be invoked with `cargo clippy` on most platforms. It also functions as a standalone `clippy-driver` tool for projects that don't use cargo. The tool can automatically apply suggestions to code in many cases, similar to the Rust compiler's own `--fix` capability. Configuration options allow developers to fine-tune lint behavior, set minimum Rust versions to avoid lints for newer language features, and enable or disable specific rules on a per-crate or per-module basis.

The project serves Rust developers of all experience levels who want to improve code quality and learn idiomatic Rust patterns. Contributions are welcomed, and the project is licensed under either Apache 2.0 or MIT, consistent with the broader Rust ecosystem.

Share this video