diff --git a/compiler/rustc_codegen_ssa/src/back/archive.rs b/compiler/rustc_codegen_ssa/src/back/archive.rs
index 58558fb8c4ba2..5266d8858d47d 100644
--- a/compiler/rustc_codegen_ssa/src/back/archive.rs
+++ b/compiler/rustc_codegen_ssa/src/back/archive.rs
@@ -14,7 +14,7 @@ use tempfile::Builder as TempFileBuilder;
use std::error::Error;
use std::fs::File;
-use std::io::{self, Write};
+use std::io;
use std::path::{Path, PathBuf};
// Re-exporting for rustc_codegen_llvm::back::archive
@@ -116,12 +116,11 @@ impl<'a> ArArchiveBuilder<'a> {
}
}
-fn try_filter_fat_archs(
+fn try_filter_fat_archs<'a>(
archs: object::read::Result<&[impl FatArch]>,
target_arch: object::Architecture,
- archive_path: &Path,
- archive_map_data: &[u8],
-) -> io::Result