Skip to content

Commit

Permalink
silence warnings reported by newer rust versions
Browse files Browse the repository at this point in the history
  • Loading branch information
Keruspe committed Aug 21, 2024
1 parent ceffdc9 commit c1b8ec2
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions examples/a-chat/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ async fn connection_writer_loop(
None => break,
},
void = shutdown.next().fuse() => match void {
#[allow(unreachable_patterns)]
Some(void) => match void {},
None => break,
}
Expand Down
2 changes: 1 addition & 1 deletion src/io/buf_writer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ pin_project! {
/// # Ok(()) }) }
///```
#[derive(Debug)]
pub struct IntoInnerError<W>(W, crate::io::Error);
pub struct IntoInnerError<W>(W, #[allow(dead_code)] crate::io::Error);

impl<W: Write> BufWriter<W> {
/// Creates a new `BufWriter` with a default buffer capacity. The default is currently 8 KB,
Expand Down
2 changes: 1 addition & 1 deletion src/io/read/bytes.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ impl<T: Read + Unpin> Stream for Bytes<T> {
}
}

#[cfg(all(test, default))]
#[cfg(all(test, feature = "default"))]
mod tests {
use crate::io;
use crate::prelude::*;
Expand Down
2 changes: 1 addition & 1 deletion src/io/read/chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ impl<T: BufRead, U: BufRead> BufRead for Chain<T, U> {
}
}

#[cfg(all(test, default))]
#[cfg(all(test, feature = "default"))]
mod tests {
use crate::io;
use crate::prelude::*;
Expand Down

0 comments on commit c1b8ec2

Please sign in to comment.