RS.CLIPPY.DUPLICATE_UNDERSCORE_ARGUMENT

Function arguments having names which only differ by an underscore

This checker is a Clippy lint created by The Rust Project Contributors. The documentation shown here is a copy of the original documentation for: duplicate_underscore_argument. Copyright ©2025 The Rust Team. All rights reserved.

What it does

Checks for function arguments having the similar names differing by an underscore.

Why is this bad?

It affects code readability.

Example

fn foo(a: i32, _a: i32) {}

Use instead:

fn bar(a: i32, _b: i32) {}