External Publication
Visit Post

Pre-RFC: Deprecation and separation of the dead_code lint

Rust Internals [Unofficial] March 3, 2026
Source

chrisd:

  • dead_code: lints on unused items

Given this definition, a lint rename from dead_code to unused_definitions or similar seems like a reasonable change to propose? And keep the old name around as a no longer recommended alias (like with bad_style and nonstandard_style).

(Specifying "definitions" instead of "items" I think captures the reasoning behind the lint not linting on unused imports, as those aren't item definitions.)

Discussion in the ATmosphere

Loading comments...