Skip to content

Commit 0e14818

Browse files
Delete unnecessary command
1 parent 92f5e58 commit 0e14818

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

src/bootstrap/tool.rs

+3-7
Original file line numberDiff line numberDiff line change
@@ -268,10 +268,6 @@ macro_rules! bootstrap_tool {
268268
}
269269

270270
impl Tool {
271-
pub fn get_mode(&self) -> Mode {
272-
Mode::ToolBootstrap
273-
}
274-
275271
/// Whether this tool requires LLVM to run
276272
pub fn uses_llvm_tools(&self) -> bool {
277273
match self {
@@ -659,23 +655,23 @@ impl<'a> Builder<'a> {
659655
pub fn tool_cmd(&self, tool: Tool) -> Command {
660656
let mut cmd = Command::new(self.tool_exe(tool));
661657
let compiler = self.compiler(0, self.config.build);
662-
self.prepare_tool_cmd(compiler, tool, &mut cmd);
658+
self.prepare_tool_cmd(compiler, &mut cmd);
663659
cmd
664660
}
665661

666662
/// Prepares the `cmd` provided to be able to run the `compiler` provided.
667663
///
668664
/// Notably this munges the dynamic library lookup path to point to the
669665
/// right location to run `compiler`.
670-
fn prepare_tool_cmd(&self, compiler: Compiler, tool: Tool, cmd: &mut Command) {
666+
fn prepare_tool_cmd(&self, compiler: Compiler, cmd: &mut Command) {
671667
let host = &compiler.host;
672668
let mut lib_paths: Vec<PathBuf> = vec![
673669
if compiler.stage == 0 {
674670
self.build.rustc_snapshot_libdir()
675671
} else {
676672
PathBuf::from(&self.sysroot_libdir(compiler, compiler.host))
677673
},
678-
self.cargo_out(compiler, tool.get_mode(), *host).join("deps"),
674+
self.cargo_out(compiler, Mode::ToolBootstrap, *host).join("deps"),
679675
];
680676

681677
// On MSVC a tool may invoke a C compiler (e.g., compiletest in run-make

0 commit comments

Comments
 (0)