From 43929a8a75d85ae3939a80703bdd827e81c51ba5 Mon Sep 17 00:00:00 2001 From: bjorn3 <17426603+bjorn3@users.noreply.github.com> Date: Tue, 14 Jun 2022 15:11:14 +0000 Subject: Remove src_files and remove_file They only apply to the main source archive and their role can be fulfilled through the skip argument of add_archive too. --- compiler/rustc_codegen_gcc/src/archive.rs | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'compiler/rustc_codegen_gcc') diff --git a/compiler/rustc_codegen_gcc/src/archive.rs b/compiler/rustc_codegen_gcc/src/archive.rs index fac532f3e9c..1975035ae20 100644 --- a/compiler/rustc_codegen_gcc/src/archive.rs +++ b/compiler/rustc_codegen_gcc/src/archive.rs @@ -70,19 +70,6 @@ impl<'a> ArchiveBuilder<'a> for ArArchiveBuilder<'a> { } } - fn src_files(&mut self) -> Vec { - self.entries.iter().map(|(name, _)| name.clone()).collect() - } - - fn remove_file(&mut self, name: &str) { - let index = self - .entries - .iter() - .position(|(entry_name, _)| entry_name == name) - .expect("Tried to remove file not existing in src archive"); - self.entries.remove(index); - } - fn add_file(&mut self, file: &Path) { self.entries.push(( file.file_name().unwrap().to_str().unwrap().to_string(), -- cgit 1.4.1-3-g733a5