chore(body): fix unused import in chunk benchmarks
This commit is contained in:
@@ -66,6 +66,10 @@ __internal_flaky_tests = []
|
|||||||
codegen-units = 1
|
codegen-units = 1
|
||||||
incremental = false
|
incremental = false
|
||||||
|
|
||||||
|
[profile.bench]
|
||||||
|
codegen-units = 1
|
||||||
|
incremental = false
|
||||||
|
|
||||||
[[example]]
|
[[example]]
|
||||||
name = "client"
|
name = "client"
|
||||||
path = "examples/client.rs"
|
path = "examples/client.rs"
|
||||||
|
|||||||
@@ -162,8 +162,6 @@ impl ExactSizeIterator for IntoIter {}
|
|||||||
|
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests {
|
mod tests {
|
||||||
use super::*;
|
|
||||||
|
|
||||||
#[cfg(feature = "nightly")]
|
#[cfg(feature = "nightly")]
|
||||||
use test::Bencher;
|
use test::Bencher;
|
||||||
|
|
||||||
@@ -178,7 +176,7 @@ mod tests {
|
|||||||
let mut dst = Vec::with_capacity(128);
|
let mut dst = Vec::with_capacity(128);
|
||||||
|
|
||||||
b.iter(|| {
|
b.iter(|| {
|
||||||
let chunk = Chunk::from(s);
|
let chunk = ::Chunk::from(s);
|
||||||
dst.put(chunk);
|
dst.put(chunk);
|
||||||
::test::black_box(&dst);
|
::test::black_box(&dst);
|
||||||
unsafe { dst.set_len(0); }
|
unsafe { dst.set_len(0); }
|
||||||
|
|||||||
Reference in New Issue
Block a user