cargo fmt --all

This commit is contained in:
Chris Hennick 2024-04-19 18:52:45 -07:00
parent 174825229c
commit e4d0a0228a
No known key found for this signature in database
GPG key ID: DA47AABA4961C509
2 changed files with 3 additions and 6 deletions

View file

@ -9,8 +9,7 @@ use zip::{write::SimpleFileOptions, ZipArchive, ZipWriter};
fn generate_random_archive(size: usize) -> Vec<u8> {
let data = Vec::new();
let mut writer = ZipWriter::new(Cursor::new(data));
let options =
SimpleFileOptions::default().compression_method(zip::CompressionMethod::Stored);
let options = SimpleFileOptions::default().compression_method(zip::CompressionMethod::Stored);
writer.start_file("random.dat", options).unwrap();
let mut bytes = vec![0u8; size];

View file

@ -10,8 +10,7 @@ fn main() {
std::process::exit(real_main());
}
const METHOD_STORED: Option<zip::CompressionMethod> =
Some(zip::CompressionMethod::Stored);
const METHOD_STORED: Option<zip::CompressionMethod> = Some(zip::CompressionMethod::Stored);
#[cfg(any(
feature = "deflate",
@ -19,8 +18,7 @@ const METHOD_STORED: Option<zip::CompressionMethod> =
feature = "deflate-zlib",
feature = "deflate-zlib-ng"
))]
const METHOD_DEFLATED: Option<zip::CompressionMethod> =
Some(zip::CompressionMethod::Deflated);
const METHOD_DEFLATED: Option<zip::CompressionMethod> = Some(zip::CompressionMethod::Deflated);
#[cfg(not(any(
feature = "deflate",
feature = "deflate-miniz",