Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
5a446c1
Fix `window.hashchange is not a function`
fmckeogh Aug 21, 2019
b2b9b81
Account for doc comments coming from proc macros without spans
estebank Aug 27, 2019
7ed542d
add regression test
estebank Aug 27, 2019
5da1123
Update zx_time_t to an i64
tmandry Aug 30, 2019
403701f
Don't try to use /dev/null on Fuchsia
tmandry Aug 30, 2019
7bfa2be
fuchsia: Don't fail to spawn if no stdin exists
tmandry Aug 31, 2019
5f91ad0
fuchsia: Fix default environment behavior when spawning
tmandry Aug 31, 2019
3c4d157
Fix unlock ordering in SGX synchronization primitives
Aug 31, 2019
5e933b4
Add x86_64-linux-kernel target
alex Aug 31, 2019
6ed50f4
Rename test locals to work around LLDB bug
ranweiler Sep 1, 2019
35c9e5f
Fix const_err with `-(-0.0)`
JohnTitor Sep 1, 2019
3a6aada
Add `opt-level` check
JohnTitor Sep 1, 2019
4a0872b
Add `overflow_check` check
JohnTitor Sep 1, 2019
8e9825a
Fix overflow_check
JohnTitor Sep 1, 2019
0cd9c16
Fix condition and tests' flags
JohnTitor Sep 1, 2019
a937d8c
Fix tests again
JohnTitor Sep 1, 2019
46877e2
Fix const eval bug breaking run-pass tests in Miri
wesleywiser Aug 29, 2019
fa893a3
use TokenStream rather than &[TokenTree] for built-in macros
matklad Aug 31, 2019
6136495
use consistent naming for buildin expansion functions
matklad Sep 3, 2019
41deb83
Add compile flag
JohnTitor Sep 4, 2019
a0c186c
remove XID and Pattern_White_Space unicode tables from libcore
matklad Jul 21, 2019
206fe8e
flatten rustc_lexer::character_properties module
matklad Sep 4, 2019
c86ea34
Ensure all warnings are emitted even on warnings=warn
Mark-Simulacrum Sep 2, 2019
fda251b
Rename --warnings=allow to --warnings=warn
Mark-Simulacrum Sep 2, 2019
669c3e3
Thread in-tree information through Mode
Mark-Simulacrum Sep 4, 2019
a2384cb
Move warnings out of rustc wrapper
Mark-Simulacrum Sep 4, 2019
e0630ab
Rollup merge of #62848 - matklad:xid-unicode, r=petrochenkov
Centril Sep 5, 2019
789d9b7
Rollup merge of #63774 - chocol4te:fix_63707, r=GuillaumeGomez
Centril Sep 5, 2019
58b84bf
Rollup merge of #63930 - estebank:rustdoc-ice, r=GuillaumeGomez
Centril Sep 5, 2019
58252da
Rollup merge of #64023 - tmandry:libstd-fuchsia-fixes, r=cramertj
Centril Sep 5, 2019
3c82d1e
Rollup merge of #64030 - jethrogb:jb/sgx-sync-issues, r=alexcrichton
Centril Sep 5, 2019
1294d80
Rollup merge of #64041 - matklad:token-stream-tt, r=petrochenkov
Centril Sep 5, 2019
5102c1e
Rollup merge of #64051 - alex:linux-kernel-module-target, r=joshtriplett
Centril Sep 5, 2019
665c473
Rollup merge of #64052 - ranweiler:debuginfo-boxed-struct-64050, r=al…
Centril Sep 5, 2019
b683631
Rollup merge of #64063 - JohnTitor:fix-const-err, r=oli-obk
Centril Sep 5, 2019
2f8cbfc
Rollup merge of #64098 - Mark-Simulacrum:always-warn, r=alexcrichton
Centril Sep 5, 2019
d43b9f3
Rollup merge of #64100 - wesleywiser:fix_miri_const_eval, r=oli-obk
Centril Sep 5, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Thread in-tree information through Mode
  • Loading branch information
Mark-Simulacrum committed Sep 4, 2019
commit 669c3e3b935014f6f3e3c30eae1ddd55806490f9
19 changes: 13 additions & 6 deletions src/bootstrap/builder.rs
Original file line number Diff line number Diff line change
Expand Up @@ -765,7 +765,9 @@ impl<'a> Builder<'a> {
if cmd == "doc" || cmd == "rustdoc" {
let my_out = match mode {
// This is the intended out directory for compiler documentation.
Mode::Rustc | Mode::ToolRustc | Mode::Codegen => self.compiler_doc_out(target),
Mode::Rustc | Mode::ToolRustc { .. } | Mode::Codegen => {
self.compiler_doc_out(target)
}
_ => self.crate_doc_out(target),
};
let rustdoc = self.rustdoc(compiler);
Expand Down Expand Up @@ -797,8 +799,8 @@ impl<'a> Builder<'a> {
}

match mode {
Mode::Std | Mode::ToolBootstrap | Mode::ToolStd => {},
Mode::Rustc | Mode::Codegen | Mode::ToolRustc => {
Mode::Std | Mode::ToolBootstrap { .. } | Mode::ToolStd { .. } => {},
Mode::Rustc | Mode::Codegen | Mode::ToolRustc { .. } => {
// Build proc macros both for the host and the target
if target != compiler.host && cmd != "check" {
cargo.arg("-Zdual-proc-macros");
Expand Down Expand Up @@ -891,7 +893,11 @@ impl<'a> Builder<'a> {
// the stage0 build means it uses libraries build by the stage0
// compiler, but for tools we just use the precompiled libraries that
// we've downloaded
let use_snapshot = mode == Mode::ToolBootstrap;
let use_snapshot = if let Mode::ToolBootstrap { .. } = mode {
true
} else {
false
};
assert!(!use_snapshot || stage == 0 || self.local_rebuild);

let maybe_sysroot = self.sysroot(compiler);
Expand Down Expand Up @@ -944,8 +950,9 @@ impl<'a> Builder<'a> {
let debuginfo_level = match mode {
Mode::Rustc | Mode::Codegen => self.config.rust_debuginfo_level_rustc,
Mode::Std => self.config.rust_debuginfo_level_std,
Mode::ToolBootstrap | Mode::ToolStd |
Mode::ToolRustc => self.config.rust_debuginfo_level_tools,
Mode::ToolBootstrap { .. } | Mode::ToolStd { .. } | Mode::ToolRustc { .. } => {
self.config.rust_debuginfo_level_tools
}
};
cargo.env("RUSTC_DEBUGINFO_LEVEL", debuginfo_level.to_string());

Expand Down
8 changes: 4 additions & 4 deletions src/bootstrap/check.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
use crate::compile::{run_cargo, std_cargo, rustc_cargo, rustc_cargo_env,
add_to_sysroot};
use crate::builder::{RunConfig, Builder, Kind, ShouldRun, Step};
use crate::tool::{prepare_tool_cargo, SourceType};
use crate::tool::prepare_tool_cargo;
use crate::{Compiler, Mode};
use crate::cache::{INTERNER, Interned};
use std::path::PathBuf;
Expand Down Expand Up @@ -187,11 +187,10 @@ impl Step for Rustdoc {

let mut cargo = prepare_tool_cargo(builder,
compiler,
Mode::ToolRustc,
Mode::ToolRustc { in_tree: true },
target,
cargo_subcommand(builder.kind),
"src/tools/rustdoc",
SourceType::InTree,
&[]);

println!("Checking rustdoc artifacts ({} -> {})", &compiler.host, target);
Expand Down Expand Up @@ -244,6 +243,7 @@ pub fn rustdoc_stamp(
compiler: Compiler,
target: Interned<String>,
) -> PathBuf {
builder.cargo_out(compiler, Mode::ToolRustc, target)
// doesn't really matter whether we're in-tree or not
builder.cargo_out(compiler, Mode::ToolRustc { in_tree: true }, target)
.join(".rustdoc-check.stamp")
}
7 changes: 3 additions & 4 deletions src/bootstrap/doc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ use build_helper::{t, up_to_date};

use crate::util::symlink_dir;
use crate::builder::{Builder, Compiler, RunConfig, ShouldRun, Step};
use crate::tool::{self, prepare_tool_cargo, Tool, SourceType};
use crate::tool::{self, prepare_tool_cargo, Tool};
use crate::compile;
use crate::cache::{INTERNER, Interned};
use crate::config::Config;
Expand Down Expand Up @@ -633,7 +633,7 @@ impl Step for Rustdoc {
builder.ensure(tool::Rustdoc { compiler: compiler });

// Symlink compiler docs to the output directory of rustdoc documentation.
let out_dir = builder.stage_out(compiler, Mode::ToolRustc)
let out_dir = builder.stage_out(compiler, Mode::ToolRustc { in_tree: true })
.join(target)
.join("doc");
t!(fs::create_dir_all(&out_dir));
Expand All @@ -643,11 +643,10 @@ impl Step for Rustdoc {
let mut cargo = prepare_tool_cargo(
builder,
compiler,
Mode::ToolRustc,
Mode::ToolRustc { in_tree: true },
target,
"doc",
"src/tools/rustdoc",
SourceType::InTree,
&[]
);

Expand Down
12 changes: 6 additions & 6 deletions src/bootstrap/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -304,19 +304,19 @@ pub enum Mode {
/// "other" here is for miscellaneous sets of tools that are built using the
/// bootstrap compiler in its entirety (target libraries and all).
/// Typically these tools compile with stable Rust.
ToolBootstrap,
ToolBootstrap { in_tree: bool },

/// Compile a tool which uses all libraries we compile (up to rustc).
/// Doesn't use the stage0 compiler libraries like "other", and includes
/// tools like rustdoc, cargo, rls, etc.
ToolStd,
ToolRustc,
ToolStd { in_tree: bool },
ToolRustc { in_tree: bool },
}

impl Mode {
pub fn is_tool(&self) -> bool {
match self {
Mode::ToolBootstrap | Mode::ToolRustc | Mode::ToolStd => true,
Mode::ToolBootstrap { .. } | Mode::ToolRustc { .. } | Mode::ToolStd { .. } => true,
_ => false
}
}
Expand Down Expand Up @@ -528,8 +528,8 @@ impl Build {
Mode::Std => "-std",
Mode::Rustc => "-rustc",
Mode::Codegen => "-codegen",
Mode::ToolBootstrap => "-bootstrap-tools",
Mode::ToolStd | Mode::ToolRustc => "-tools",
Mode::ToolBootstrap { .. } => "-bootstrap-tools",
Mode::ToolStd { .. } | Mode::ToolRustc { .. } => "-tools",
};
self.out.join(&*compiler.host)
.join(format!("stage{}{}", compiler.stage, suffix))
Expand Down
28 changes: 10 additions & 18 deletions src/bootstrap/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ use crate::compile;
use crate::dist;
use crate::flags::Subcommand;
use crate::native;
use crate::tool::{self, Tool, SourceType};
use crate::tool::{self, Tool};
use crate::toolstate::ToolState;
use crate::util::{self, dylib_path, dylib_path_var};
use crate::Crate as CargoCrate;
Expand Down Expand Up @@ -213,11 +213,10 @@ impl Step for Cargo {
});
let mut cargo = tool::prepare_tool_cargo(builder,
compiler,
Mode::ToolRustc,
Mode::ToolRustc { in_tree: false },
self.host,
"test",
"src/tools/cargo",
SourceType::Submodule,
&[]);

if !builder.fail_fast {
Expand Down Expand Up @@ -279,11 +278,10 @@ impl Step for Rls {

let mut cargo = tool::prepare_tool_cargo(builder,
compiler,
Mode::ToolRustc,
Mode::ToolRustc { in_tree: false },
host,
"test",
"src/tools/rls",
SourceType::Submodule,
&[]);

builder.add_rustc_lib_path(compiler, &mut cargo);
Expand Down Expand Up @@ -335,11 +333,10 @@ impl Step for Rustfmt {

let mut cargo = tool::prepare_tool_cargo(builder,
compiler,
Mode::ToolRustc,
Mode::ToolRustc { in_tree: false },
host,
"test",
"src/tools/rustfmt",
SourceType::Submodule,
&[]);

let dir = testdir(builder, compiler.host);
Expand Down Expand Up @@ -392,11 +389,10 @@ impl Step for Miri {
let mut cargo = tool::prepare_tool_cargo(
builder,
compiler,
Mode::ToolRustc,
Mode::ToolRustc { in_tree: false },
host,
"run",
"src/tools/miri",
SourceType::Submodule,
&[],
);
cargo
Expand Down Expand Up @@ -451,11 +447,10 @@ impl Step for Miri {
let mut cargo = tool::prepare_tool_cargo(
builder,
compiler,
Mode::ToolRustc,
Mode::ToolRustc { in_tree: false },
host,
"test",
"src/tools/miri",
SourceType::Submodule,
&[],
);

Expand Down Expand Up @@ -504,11 +499,10 @@ impl Step for CompiletestTest {

let mut cargo = tool::prepare_tool_cargo(builder,
compiler,
Mode::ToolBootstrap,
Mode::ToolBootstrap { in_tree: true },
host,
"test",
"src/tools/compiletest",
SourceType::InTree,
&[]);

try_run(builder, &mut cargo);
Expand Down Expand Up @@ -551,19 +545,18 @@ impl Step for Clippy {
if let Some(clippy) = clippy {
let mut cargo = tool::prepare_tool_cargo(builder,
compiler,
Mode::ToolRustc,
Mode::ToolRustc { in_tree: false },
host,
"test",
"src/tools/clippy",
SourceType::Submodule,
&[]);

// clippy tests need to know about the stage sysroot
cargo.env("SYSROOT", builder.sysroot(compiler));
cargo.env("RUSTC_TEST_SUITE", builder.rustc(compiler));
cargo.env("RUSTC_LIB_PATH", builder.rustc_libdir(compiler));
let host_libs = builder
.stage_out(compiler, Mode::ToolRustc)
.stage_out(compiler, Mode::ToolRustc { in_tree: false })
.join(builder.cargo_dir());
cargo.env("HOST_LIBS", host_libs);
// clippy tests need to find the driver
Expand Down Expand Up @@ -1877,11 +1870,10 @@ impl Step for CrateRustdoc {

let mut cargo = tool::prepare_tool_cargo(builder,
compiler,
Mode::ToolRustc,
Mode::ToolRustc { in_tree: true },
target,
test_kind.subcommand(),
"src/tools/rustdoc",
SourceType::InTree,
&[]);
if test_kind.subcommand() == "test" && !builder.fail_fast {
cargo.arg("--no-fail-fast");
Expand Down
Loading