Skip to content

Commit

Permalink
Fix dead code warnings in tests
Browse files Browse the repository at this point in the history
rust-lang/rust#118257 has improved the detection of unused traits
  • Loading branch information
Nemo157 committed Feb 8, 2024
1 parent 033a870 commit 0f2338f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions tests/throws.rs
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ pub fn unreachable() {
todo!()
}

#[allow(dead_code)]
trait Example {
#[throws]
fn foo() -> i32;
Expand Down
1 change: 1 addition & 0 deletions tests/try.rs
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ pub fn unreachable() -> Result<(), i32> {
todo!()
}

#[allow(dead_code)]
trait Example {
#[try_fn]
fn foo() -> Result<i32, Error>;
Expand Down

0 comments on commit 0f2338f

Please sign in to comment.