]> git.lizzy.rs Git - rust.git/commitdiff
Auto merge of #6601 - mdm:fix-unit-args-false-positive, r=camsteffen
authorbors <bors@rust-lang.org>
Thu, 25 Feb 2021 21:16:02 +0000 (21:16 +0000)
committerbors <bors@rust-lang.org>
Thu, 25 Feb 2021 21:16:02 +0000 (21:16 +0000)
Fix false positive for unit_arg lint

Fixes #6447

To avoid false positives don't complain about unit args when they come from a path expression, e.g. a local variable.

**Note:** This is my first contribution to Clippy, so I might have messed up somewhere. Any feedback is welcome and I'm happy to work out any kinks.

---

changelog: Do not lint unit arguments when they come from a path expression.

1  2 
clippy_lints/src/types.rs

Simple merge