Skip to content

Commit 73a40ac

Browse files
committed
Inline maybe_update_submodule
It was a trivial function only used once.
1 parent 2fbe2ca commit 73a40ac

File tree

1 file changed

+5
-9
lines changed

1 file changed

+5
-9
lines changed

src/bootstrap/lib.rs

+5-9
Original file line numberDiff line numberDiff line change
@@ -472,21 +472,17 @@ impl Build {
472472
slice::from_ref(&self.build.triple)
473473
}
474474

475-
/// If the LLVM submodule has been initialized already, sync it unconditionally. This avoids
476-
/// contributors checking in a submodule change by accident.
477-
pub fn maybe_update_llvm_submodule(&self) {
478-
if self.in_tree_llvm_info.is_git() {
479-
native::update_llvm_submodule(self);
480-
}
481-
}
482-
483475
/// Executes the entire build, as configured by the flags and configuration.
484476
pub fn build(&mut self) {
485477
unsafe {
486478
job::setup(self);
487479
}
488480

489-
self.maybe_update_llvm_submodule();
481+
// If the LLVM submodule has been initialized already, sync it unconditionally. This avoids
482+
// contributors checking in a submodule change by accident.
483+
if self.in_tree_llvm_info.is_git() {
484+
native::update_llvm_submodule(self);
485+
}
490486

491487
if let Subcommand::Format { check, paths } = &self.config.cmd {
492488
return format::format(self, *check, &paths);

0 commit comments

Comments
 (0)