Open
Description
I tried this code:
foo.rs
:
#![crate_type = "rlib"]
pub struct FooStruct;
pub trait FooTrait {
/// docs
///
/// more docs
fn foo_method();
}
impl FooTrait for FooStruct {
fn foo_method() {}
}
bar.rs
:
extern crate foo;
pub use foo::FooStruct;
running rustc foo.rs && rustdoc -L . bar.rs
so only bar
is documented.
I expected to see this happen:
When the docs for bar
are documented the page for FooStruct
shouldn't contain any broken "Read more" links.
Instead, this happened:
The "Read more" link for foo_method
on the page for FooStruct
points to #tymethod.foo_method
which doesn't go anywhere. It should point to the documentation for FooTrait
but as that page doesn't exist the "Read more" link shouldn't exist at all. The link works fine if docs for foo
are also generated or pub use foo::FooTrait;
is added to bar.rs
.
Meta
rustc --version --verbose
:
rustc 1.46.0-nightly (5db778aff 2020-07-09)
binary: rustc
commit-hash: 5db778affee7c6600c8e7a177c48282dab3f6292
commit-date: 2020-07-09
host: x86_64-pc-windows-msvc
release: 1.46.0-nightly
LLVM version: 10.0