From 25960a47d24af04cfa1558e8ca83bbd969e226c7 Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Wed, 31 Aug 2022 00:02:55 -0700 Subject: [PATCH] Avoid unused_self clippy pedantic lint in test error: unused `self` argument --> tests/test_expr.rs:266:25 | 266 | fn consume_self(self) {} | ^^^^ | = note: `-D clippy::unused-self` implied by `-D clippy::pedantic` = help: consider refactoring to a associated function = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unused_self --- tests/test_expr.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/test_expr.rs b/tests/test_expr.rs index fcb6e00..8ad5de9 100644 --- a/tests/test_expr.rs +++ b/tests/test_expr.rs @@ -263,7 +263,9 @@ fn test_top_level_none_delimiter() { struct A; impl A { - fn consume_self(self) {} + fn consume_self(self) { + let _ = self; + } } clone!(&A).consume_self();