Skip to content
Merged
Changes from 1 commit
Commits
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
20 changes: 16 additions & 4 deletions src/bootstrap/src/core/build_steps/doc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -965,9 +965,11 @@ macro_rules! tool_doc {
(
$tool: ident,
$path: literal,
mode = $mode:expr,
$(is_library = $is_library:expr,)?
$(crates = $crates:expr)?
mode = $mode:expr
$(, is_library = $is_library:expr )?
$(, crates = $crates:expr )?
// Subset of nightly features that are allowed to be used when documenting
$(, allow_features: $allow_features:expr )?
) => {
#[derive(Debug, Clone, Hash, PartialEq, Eq)]
pub struct $tool {
Expand Down Expand Up @@ -1041,6 +1043,15 @@ macro_rules! tool_doc {
source_type,
&[],
);
let allow_features = {
let mut _value = "";
$( _value = $allow_features; )?
_value
};

if allow_features.is_empty() {
cargo.allow_features(allow_features);
}

cargo.arg("-Zskip-rustdoc-fingerprint");
// Only include compiler crates, no dependencies of those, such as `libc`.
Expand Down Expand Up @@ -1134,7 +1145,8 @@ tool_doc!(
"crates-io",
"mdman",
"rustfix",
]
],
allow_features: "specialization"
);
tool_doc!(Tidy, "src/tools/tidy", mode = Mode::ToolBootstrap, crates = ["tidy"]);
tool_doc!(
Expand Down