Ignore dead_code warning for tuple struct

This lint does not take into account destructors.

```
error: field `0` is never read
    --> src\iocp\mod.rs:1155:13
     |
1155 |     Waiting(WaitHandle),
     |     ------- ^^^^^^^^^^
     |     |
     |     field in this variant
     |
     = note: `-D dead-code` implied by `-D warnings`
     = help: to override `-D warnings` add `#[allow(dead_code)]`
help: consider changing the field to be of unit type to suppress this warning while preserving the field numbering, or remove the field
     |
1155 |     Waiting(()),
     |             ~~
```
This commit is contained in:
Taiki Endo 2024-01-07 15:44:43 +09:00
parent 94c5ebf78b
commit 0c794fce50
1 changed files with 1 additions and 1 deletions

View File

@ -1152,7 +1152,7 @@ enum WaitableStatus {
Idle,
/// We are waiting on this handle to become signaled.
Waiting(WaitHandle),
Waiting(#[allow(dead_code)] WaitHandle),
/// This handle has been cancelled.
Cancelled,