Fix RESTRICTED_DEPENDENCY_CRATES to list rustc_driver instead of rustc_middle

This commit is contained in:
bjorn3 2021-05-03 18:36:06 +02:00
parent e327a823d8
commit d7cd6e2426

View file

@ -49,7 +49,7 @@ const EXCEPTIONS: &[(&str, &str)] = &[
const RUNTIME_CRATES: &[&str] = &["std", "core", "alloc", "test", "panic_abort", "panic_unwind"];
/// Crates whose dependencies must be explicitly permitted.
const RESTRICTED_DEPENDENCY_CRATES: &[&str] = &["rustc_middle", "rustc_codegen_llvm"];
const RESTRICTED_DEPENDENCY_CRATES: &[&str] = &["rustc_driver", "rustc_codegen_llvm"];
/// Crates rustc is allowed to depend on. Avoid adding to the list if possible.
///
@ -72,7 +72,10 @@ const PERMITTED_DEPENDENCIES: &[&str] = &[
"cc",
"cfg-if",
"chalk-derive",
"chalk-engine",
"chalk-ir",
"chalk-solve",
"chrono",
"cmake",
"compiler_builtins",
"cpuid-bool",
@ -92,6 +95,7 @@ const PERMITTED_DEPENDENCIES: &[&str] = &[
"expect-test",
"fake-simd",
"filetime",
"fixedbitset",
"flate2",
"fortanix-sgx-abi",
"fuchsia-zircon",
@ -107,6 +111,7 @@ const PERMITTED_DEPENDENCIES: &[&str] = &[
"indexmap",
"instant",
"itertools",
"itoa",
"jobserver",
"kernel32-sys",
"lazy_static",
@ -114,6 +119,7 @@ const PERMITTED_DEPENDENCIES: &[&str] = &[
"libz-sys",
"lock_api",
"log",
"matchers",
"maybe-uninit",
"md-5",
"measureme",
@ -123,6 +129,8 @@ const PERMITTED_DEPENDENCIES: &[&str] = &[
"memoffset",
"miniz_oxide",
"num_cpus",
"num-integer",
"num-traits",
"object",
"once_cell",
"opaque-debug",
@ -130,6 +138,7 @@ const PERMITTED_DEPENDENCIES: &[&str] = &[
"parking_lot_core",
"pathdiff",
"perf-event-open-sys",
"petgraph",
"pin-project-lite",
"pkg-config",
"polonius-engine",
@ -147,22 +156,28 @@ const PERMITTED_DEPENDENCIES: &[&str] = &[
"rand_xorshift",
"redox_syscall",
"regex",
"regex-automata",
"regex-syntax",
"remove_dir_all",
"rls-data",
"rls-span",
"rustc-demangle",
"rustc-hash",
"rustc-rayon",
"rustc-rayon-core",
"rustc_version",
"ryu",
"scoped-tls",
"scopeguard",
"semver",
"semver-parser",
"serde",
"serde_derive",
"serde_json",
"sha-1",
"sha2",
"smallvec",
"sharded-slab",
"snap",
"stable_deref_trait",
"stacker",
@ -172,9 +187,15 @@ const PERMITTED_DEPENDENCIES: &[&str] = &[
"termcolor",
"termize",
"thread_local",
"time",
"tinyvec",
"tracing",
"tracing-attributes",
"tracing-core",
"tracing-log",
"tracing-serde",
"tracing-subscriber",
"tracing-tree",
"typenum",
"unicode-normalization",
"unicode-script",