We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 82d7cd4 commit 9848c66Copy full SHA for 9848c66
build_system/src/fuzz/reduce.rs
@@ -39,7 +39,6 @@ fn remove_dup_assign(
39
ends: usize,
40
cache: &mut ResultCache,
41
) {
42
- let mut curr = 0;
43
let mut file_copy = file.clone();
44
let mut reduction_count = 0;
45
// Not worth it.
@@ -427,7 +426,6 @@ pub(super) fn reduce(path: impl AsRef<Path>) {
427
426
println!("running `linearize_cf` on {path:?}.");
428
linearize_cf(&mut file, &path, &mut cache);
429
let mut out = std::fs::File::create(&path).expect("Could not save the reduction result.");
430
- for line in file {
431
- out.write_all(line.as_bytes());
432
- }
+ let file = file.into_iter().collect::<String>();
+ out.write_all(file.as_bytes()).expect("failed to write into file");
433
}
0 commit comments