Fixed clippy warning

This commit is contained in:
kinire98 2024-02-12 17:48:49 +01:00
parent d0dbdad856
commit 083e6ae85c
2 changed files with 3 additions and 6 deletions

View File

@ -56,7 +56,7 @@ name = "benchmarks"
harness = false
[features]
default = ["async-std", "mmap"]
default = ["async-std", "mmap", "link_to"]
mmap = ["memmap2", "libc"]
async-std = ["dep:async-std", "futures"]
link_to = []

View File

@ -1,5 +1,7 @@
#[cfg(any(feature = "async-std", feature = "tokio"))]
use crate::async_lib::AsyncRead;
#[cfg(any(feature = "async-std", feature = "tokio"))]
use crate::async_lib::AsyncReadExt;
use crate::content::linkto;
use crate::errors::{Error, IoErrorExt, Result};
use crate::{index, WriteOpts};
@ -11,11 +13,6 @@ use std::pin::Pin;
#[cfg(any(feature = "async-std", feature = "tokio"))]
use std::task::{Context as TaskContext, Poll};
#[cfg(feature = "async-std")]
use futures::io::AsyncReadExt;
#[cfg(feature = "tokio")]
use tokio::io::AsyncReadExt;
const BUF_SIZE: usize = 16 * 1024;
const PROBE_SIZE: usize = 8;