Skip to content

Cross-crate import chain misses docs from middle crate #120927

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
dhardy opened this issue Feb 11, 2024 · 1 comment
Open

Cross-crate import chain misses docs from middle crate #120927

dhardy opened this issue Feb 11, 2024 · 1 comment
Labels
A-cross-crate-reexports Area: Documentation that has been re-exported from a different crate C-bug Category: This is a bug. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.

Comments

@dhardy
Copy link
Contributor

dhardy commented Feb 11, 2024

Given crates a:

/// (doc in a)
pub fn foo() {}

b:

/// (doc in b)
#[doc(inline)]
pub use a::foo;

and c:

/// (doc in master crate)
#[doc(inline)]
pub use b::foo;

The resulting rustdoc output for c omits documentation added in b:
image
I would expect the docs from all crates to be included.

Source for reproduction

inline-doc-reexport.zip

Related

#84619
#89020
@rustbot label +A-cross-crate-reexports +T-rustdoc

@rustbot rustbot added needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. A-cross-crate-reexports Area: Documentation that has been re-exported from a different crate T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Feb 11, 2024
@dhardy
Copy link
Contributor Author

dhardy commented Feb 11, 2024

This also applies to re-exports via

#[doc(inline)]
pub extern crate b;

@saethlin saethlin removed the needs-triage This issue may need triage. Remove it if it has been sufficiently triaged. label Feb 13, 2024
@fmease fmease added the C-bug Category: This is a bug. label Feb 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-cross-crate-reexports Area: Documentation that has been re-exported from a different crate C-bug Category: This is a bug. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

No branches or pull requests

4 participants