diff options
| author | Mark Simulacrum <mark.simulacrum@gmail.com> | 2017-06-27 13:34:26 -0600 |
|---|---|---|
| committer | Mark Simulacrum <mark.simulacrum@gmail.com> | 2017-07-04 07:31:56 -0600 |
| commit | 712bd0d841469f8ed42d555ed714fee06beb14fa (patch) | |
| tree | 894ab5a94ca1851d87b5be7c0149d3e8add814e0 /src/bootstrap | |
| parent | 2cc5b084a0fdbd08ecc873be33bafd08d4faf273 (diff) | |
| download | rust-712bd0d841469f8ed42d555ed714fee06beb14fa.tar.gz rust-712bd0d841469f8ed42d555ed714fee06beb14fa.zip | |
Remove src_is_git, instead call method on rust_info directly.
Diffstat (limited to 'src/bootstrap')
| -rw-r--r-- | src/bootstrap/channel.rs | 4 | ||||
| -rw-r--r-- | src/bootstrap/dist.rs | 2 | ||||
| -rw-r--r-- | src/bootstrap/lib.rs | 2 | ||||
| -rw-r--r-- | src/bootstrap/sanity.rs | 2 |
4 files changed, 6 insertions, 4 deletions
diff --git a/src/bootstrap/channel.rs b/src/bootstrap/channel.rs index 199c01cf821..1153acfa57d 100644 --- a/src/bootstrap/channel.rs +++ b/src/bootstrap/channel.rs @@ -101,4 +101,8 @@ impl GitInfo { } version } + + pub fn is_git(&self) -> bool { + self.inner.is_some() + } } diff --git a/src/bootstrap/dist.rs b/src/bootstrap/dist.rs index c91d6f0b77c..2f7c1f038a1 100644 --- a/src/bootstrap/dist.rs +++ b/src/bootstrap/dist.rs @@ -623,7 +623,7 @@ pub fn plain_source_tarball(build: &Build) { write_file(&plain_dst_src.join("version"), build.rust_version().as_bytes()); // If we're building from git sources, we need to vendor a complete distribution. - if build.src_is_git { + if build.rust_info.is_git() { // Get cargo-vendor installed, if it isn't already. let mut has_cargo_vendor = false; let mut cmd = Command::new(&build.initial_cargo); diff --git a/src/bootstrap/lib.rs b/src/bootstrap/lib.rs index bb82e711d7b..a6608972acd 100644 --- a/src/bootstrap/lib.rs +++ b/src/bootstrap/lib.rs @@ -183,7 +183,6 @@ pub struct Build { cxx: HashMap<String, gcc::Tool>, crates: HashMap<String, Crate>, is_sudo: bool, - src_is_git: bool, ci_env: CiEnv, delayed_failures: Cell<usize>, } @@ -262,7 +261,6 @@ impl Build { lldb_version: None, lldb_python_dir: None, is_sudo: is_sudo, - src_is_git: src_is_git, ci_env: CiEnv::current(), delayed_failures: Cell::new(0), } diff --git a/src/bootstrap/sanity.rs b/src/bootstrap/sanity.rs index d6def25cfaa..433ac3dedfd 100644 --- a/src/bootstrap/sanity.rs +++ b/src/bootstrap/sanity.rs @@ -80,7 +80,7 @@ pub fn check(build: &mut Build) { let mut cmd_finder = Finder::new(); // If we've got a git directory we're gona need git to update // submodules and learn about various other aspects. - if build.src_is_git { + if build.rust_info.is_git() { cmd_finder.must_have("git"); } |
