Cargo doc spuriously links to random enum variant fields instead of marking links broken #107903
Labels
A-intra-doc-links
Area: Intra-doc links, the ability to link to items in docs by name
C-bug
Category: This is a bug.
E-medium
Call for participation: Medium difficulty. Experience needed to fix: Intermediate.
E-mentor
Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.
T-rustdoc
Relevant to the rustdoc team, which will review and decide on the PR/issue.
Uh oh!
There was an error while loading. Please reload this page.
Problem
In lightningdevkit/rust-lightning#2027 we stumbled across a bug in
cargo doc
, as it checking for broken links didn't work for a now renamed field that is also present in anotherenum
variant.Steps
A minimal example is this, which doesn't fail, but should:
If
TestEnum::Variant1::field_name
is present the docs indeed link to the right variant. If it is missing,cargo doc
gladly makes theTestEnum::Variant1::field_name
link point toTestEnum::Variant2::field_name
, without throwing an error.Possible Solution(s)
No response
Notes
No response
Version
The text was updated successfully, but these errors were encountered: