Skip to content

Commit

Permalink
Fix clippy::shadow_same warning
Browse files Browse the repository at this point in the history
  • Loading branch information
c410-f3r committed Dec 9, 2021
1 parent c5de48e commit 5629db9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/expand.rs
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,8 @@ fn lint_suppress_with_body() -> Attribute {
clippy::no_effect_underscore_binding,
clippy::type_complexity,
clippy::type_repetition_in_bounds,
clippy::used_underscore_binding
clippy::used_underscore_binding,
clippy::shadow_same
)]
}
}
Expand Down
10 changes: 10 additions & 0 deletions tests/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1377,3 +1377,13 @@ pub mod issue169 {

pub fn test(_t: &dyn Trait) {}
}

// https://github.com/dtolnay/async-trait/issues/183
pub mod issue183 {
#![deny(clippy::shadow_same)]

#[async_trait::async_trait]
trait Foo {
async fn foo(_n: i32) {}
}
}

0 comments on commit 5629db9

Please sign in to comment.