Closed
Description
Found while testing #70951.
I tried this code:
In rustc_middle:
pub trait QueryEngine {
#[cfg(parallel_compiler)]
unsafe fn deadlock();
}
In downstream crate rustc_query_system:
impl QueryEngine for QueryCtxt {
#[cfg(parallel_compiler)]
unsafe fn deadlock() {}
}
I expected to see this happen: rustdoc run successfully.
Instead, this happened: rustdoc complains of missing impl-item deadlock
.
My understanding is that ./x.py check
compiles with parallel_compiler = true
and
puts the trait with deadcode
in its metadata.
Rustdoc tries to document ignoring parallel_compiler
,
so the function deadcode
is missing.
Meta
master at 8599bff