mirror of
https://github.com/rust-lang/rust-analyzer
synced 2025-01-15 22:54:00 +00:00
Make rustc_* workspace
This commit is contained in:
parent
65d39f32d6
commit
c304ceeb4c
1 changed files with 11 additions and 11 deletions
|
@ -124,16 +124,6 @@ config_data! {
|
||||||
/// This config takes a map of crate names with the exported proc-macro names to ignore as values.
|
/// This config takes a map of crate names with the exported proc-macro names to ignore as values.
|
||||||
procMacro_ignored: FxHashMap<Box<str>, Box<[Box<str>]>> = FxHashMap::default(),
|
procMacro_ignored: FxHashMap<Box<str>, Box<[Box<str>]>> = FxHashMap::default(),
|
||||||
|
|
||||||
/// Path to the Cargo.toml of the rust compiler workspace, for usage in rustc_private
|
|
||||||
/// projects, or "discover" to try to automatically find it if the `rustc-dev` component
|
|
||||||
/// is installed.
|
|
||||||
///
|
|
||||||
/// Any project which uses rust-analyzer with the rustcPrivate
|
|
||||||
/// crates must set `[package.metadata.rust-analyzer] rustc_private=true` to use it.
|
|
||||||
///
|
|
||||||
/// This option does not take effect until rust-analyzer is restarted.
|
|
||||||
rustc_source: Option<String> = None,
|
|
||||||
|
|
||||||
|
|
||||||
/// Enables automatic discovery of projects using [`DiscoverWorkspaceConfig::command`].
|
/// Enables automatic discovery of projects using [`DiscoverWorkspaceConfig::command`].
|
||||||
///
|
///
|
||||||
|
@ -433,6 +423,16 @@ config_data! {
|
||||||
/// [`rustc`’s built-in test harness (“libtest”)](https://doc.rust-lang.org/rustc/tests/index.html#cli-arguments).
|
/// [`rustc`’s built-in test harness (“libtest”)](https://doc.rust-lang.org/rustc/tests/index.html#cli-arguments).
|
||||||
runnables_extraTestBinaryArgs: Vec<String> = vec!["--show-output".to_owned()],
|
runnables_extraTestBinaryArgs: Vec<String> = vec!["--show-output".to_owned()],
|
||||||
|
|
||||||
|
/// Path to the Cargo.toml of the rust compiler workspace, for usage in rustc_private
|
||||||
|
/// projects, or "discover" to try to automatically find it if the `rustc-dev` component
|
||||||
|
/// is installed.
|
||||||
|
///
|
||||||
|
/// Any project which uses rust-analyzer with the rustcPrivate
|
||||||
|
/// crates must set `[package.metadata.rust-analyzer] rustc_private=true` to use it.
|
||||||
|
///
|
||||||
|
/// This option does not take effect until rust-analyzer is restarted.
|
||||||
|
rustc_source: Option<String> = None,
|
||||||
|
|
||||||
/// Additional arguments to `rustfmt`.
|
/// Additional arguments to `rustfmt`.
|
||||||
rustfmt_extraArgs: Vec<String> = vec![],
|
rustfmt_extraArgs: Vec<String> = vec![],
|
||||||
/// Advanced option, fully override the command rust-analyzer uses for
|
/// Advanced option, fully override the command rust-analyzer uses for
|
||||||
|
@ -1799,7 +1799,7 @@ impl Config {
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn cargo(&self, source_root: Option<SourceRootId>) -> CargoConfig {
|
pub fn cargo(&self, source_root: Option<SourceRootId>) -> CargoConfig {
|
||||||
let rustc_source = self.rustc_source().as_ref().map(|rustc_src| {
|
let rustc_source = self.rustc_source(source_root).as_ref().map(|rustc_src| {
|
||||||
if rustc_src == "discover" {
|
if rustc_src == "discover" {
|
||||||
RustLibSource::Discover
|
RustLibSource::Discover
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue