From 97d4d388823353ffcf8d718dafe5e8c5a48a2fb5 Mon Sep 17 00:00:00 2001 From: Eric Huss Date: Thu, 2 Mar 2023 10:48:46 -0800 Subject: [PATCH 1/3] Remove `dir-name` from unstable docs Allowing the `dir-name` key for profiles was removed in #9685. --- src/doc/src/reference/unstable.md | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/src/doc/src/reference/unstable.md b/src/doc/src/reference/unstable.md index 2a8984ec1b5..721bd004853 100644 --- a/src/doc/src/reference/unstable.md +++ b/src/doc/src/reference/unstable.md @@ -235,20 +235,6 @@ information from `.cargo/config.toml`. See the rustc issue for more information. cargo test --target foo -Zdoctest-xcompile ``` -#### New `dir-name` attribute - -Some of the paths generated under `target/` have resulted in a de-facto "build -protocol", where `cargo` is invoked as a part of a larger project build. So, to -preserve the existing behavior, there is also a new attribute `dir-name`, which -when left unspecified, defaults to the name of the profile. For example: - -```toml -[profile.release-lto] -inherits = "release" -dir-name = "lto" # Emits to target/lto instead of target/release-lto -lto = true -``` - ### Build-plan * Tracking Issue: [#5579](https://github.com/rust-lang/cargo/issues/5579) From a518301657191d1a892bb2597493d6f4b31c0bc5 Mon Sep 17 00:00:00 2001 From: Eric Huss Date: Thu, 2 Mar 2023 11:03:04 -0800 Subject: [PATCH 2/3] Mark `cargo:rustc-check-cfg` as a subsection of check-cfg --- src/doc/src/reference/unstable.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/doc/src/reference/unstable.md b/src/doc/src/reference/unstable.md index 721bd004853..271028d4638 100644 --- a/src/doc/src/reference/unstable.md +++ b/src/doc/src/reference/unstable.md @@ -1224,7 +1224,7 @@ println!("cargo:rustc-check-cfg=names(foo, bar)"); cargo check -Z unstable-options -Z check-cfg=output ``` -### `cargo:rustc-check-cfg=CHECK_CFG` +#### `cargo:rustc-check-cfg=CHECK_CFG` The `rustc-check-cfg` instruction tells Cargo to pass the given value to the `--check-cfg` flag to the compiler. This may be used for compile-time From c515e4a833d28b08ebe903c6543e3a5d671f7158 Mon Sep 17 00:00:00 2001 From: Eric Huss Date: Thu, 2 Mar 2023 11:03:33 -0800 Subject: [PATCH 3/3] Add missing entries to unstable index --- src/doc/src/reference/unstable.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/doc/src/reference/unstable.md b/src/doc/src/reference/unstable.md index 271028d4638..346e9fabba3 100644 --- a/src/doc/src/reference/unstable.md +++ b/src/doc/src/reference/unstable.md @@ -80,9 +80,13 @@ Each new feature described below should explain how to use it. * [binary-dep-depinfo](#binary-dep-depinfo) --- Causes the dep-info file to track binary dependencies. * [panic-abort-tests](#panic-abort-tests) --- Allows running tests with the "abort" panic strategy. * [keep-going](#keep-going) --- Build as much as possible rather than aborting on the first error. + * [check-cfg](#check-cfg) --- Compile-time validation of `cfg` expressions. + * [host-config](#host-config) --- Allows setting `[target]`-like configuration settings for host build targets. + * [target-applies-to-host](#target-applies-to-host) --- Alters whether certain flags will be passed to host build targets. * rustdoc * [`doctest-in-workspace`](#doctest-in-workspace) --- Fixes workspace-relative paths when running doctests. * [rustdoc-map](#rustdoc-map) --- Provides mappings for documentation to link to external sites like [docs.rs](https://docs.rs/). + * [scrape-examples](#scrape-examples) --- Shows examples within documentation. * `Cargo.toml` extensions * [Profile `rustflags` option](#profile-rustflags-option) --- Passed directly to rustc. * [codegen-backend](#codegen-backend) --- Select the codegen backend used by rustc.