Auto merge of #17108 - Veykril:rustc-ws-hacks, r=Veykril

internal: Cleanup cfg and env handling in project-model

Fixes https://github.com/rust-lang/rust-analyzer/issues/16122#issuecomment-2065794340

`miri` and `debug_assertions` are now enabled via the `cargo.cfgs` config by default, allowing them to be disabled by overwriting the config.
This commit is contained in:
bors 2024-04-19 16:00:54 +00:00
commit 50bdeaad07
23 changed files with 516 additions and 323 deletions

View file

@ -88,10 +88,18 @@ or build-script sources change and are saved.
Use `RUSTC_WRAPPER=rust-analyzer` when running build scripts to
avoid checking unnecessary things.
--
[[rust-analyzer.cargo.cfgs]]rust-analyzer.cargo.cfgs (default: `{}`)::
[[rust-analyzer.cargo.cfgs]]rust-analyzer.cargo.cfgs::
+
--
Default:
----
{
"debug_assertions": null,
"miri": null
}
----
List of cfg options to enable with the given values.
--
[[rust-analyzer.cargo.extraArgs]]rust-analyzer.cargo.extraArgs (default: `[]`)::
+