Skip to content

rustdoc: stability summary does not handle reexports correctly #18812

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

Closed
aturon opened this issue Nov 9, 2014 · 1 comment · Fixed by #18860
Closed

rustdoc: stability summary does not handle reexports correctly #18812

aturon opened this issue Nov 9, 2014 · 1 comment · Fixed by #18860
Labels
T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.

Comments

@aturon
Copy link
Member

aturon commented Nov 9, 2014

The stability summary page does not appear to inline across reexports properly. For example, trie_map in std::collections is currently shown as entirely experimental, but in libcollections has a non-trivial percentage of unstable items.

@aturon aturon added the T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. label Nov 9, 2014
@aturon
Copy link
Member Author

aturon commented Nov 9, 2014

This may be specific to impl blocks in re-exported modules.

aturon added a commit to aturon/rust that referenced this issue Nov 10, 2014
Previously, the stability summary page attempted to associate impl
blocks with the module in which they were defined, rather than the
module defining the type they apply to (which is usually, but not
always, the same). Unfortunately, due to the basic architecture of
rustdoc, this meant that impls from re-exports were not being counted.

This commit makes the stability summary work the same way that rustdoc's
rendered output does: all methods are counted alongside the type they
apply to, no matter where the methods are defined.

In addition, for trait impl blocks only the stability of the overall
block is counted; the stability of the methods within is not
counted (since that stability level is part of the trait definition).

Fixes rust-lang#18812
bors added a commit that referenced this issue Nov 12, 2014
Previously, the stability summary page attempted to associate impl
blocks with the module in which they were defined, rather than the
module defining the type they apply to (which is usually, but not
always, the same). Unfortunately, due to the basic architecture of
rustdoc, this meant that impls from re-exports were not being counted.

This commit makes the stability summary work the same way that rustdoc's
rendered output does: all methods are counted alongside the type they
apply to, no matter where the methods are defined.

In addition, for trait impl blocks only the stability of the overall
block is counted; the stability of the methods within is not
counted (since that stability level is part of the trait definition).

Fixes #18812
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant