-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Labels
A-cross-crate-reexportsArea: Documentation that has been re-exported from a different crateArea: Documentation that has been re-exported from a different crateA-visibilityArea: Visibility / privacyArea: Visibility / privacyC-bugCategory: This is a bug.Category: This is a bug.E-mediumCall for participation: Medium difficulty. Experience needed to fix: Intermediate.Call for participation: Medium difficulty. Experience needed to fix: Intermediate.E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.P-mediumMedium priorityMedium priorityT-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.regression-from-stable-to-stablePerformance or correctness regression from one stable version to another.Performance or correctness regression from one stable version to another.
Description
The documentation of Iterator trait on 1.49.0 (current stable) doesn't contain pub
modifier in function declaration of that trait.
However, on beta and nightly, there is pub
modifier.
This is wrong because you cannot use pub
modifier for each method/function in Trait definition.
Why is this important? People copy the method/function declaration in the documentation to their code
and see the compiler error: error[E0449]: unnecessary visibility qualifier
.
Meta
rustc --version --verbose
:
rustc 1.49.0 (e1884a8e3 2020-12-29)
binary: rustc
commit-hash: e1884a8e3c3e813aada8254edfa120e85bf5ffca
commit-date: 2020-12-29
host: x86_64-unknown-linux-gnu
release: 1.49.0
cc @jyn514 I think this might relate to some changes in visibility around macros ?
Metadata
Metadata
Assignees
Labels
A-cross-crate-reexportsArea: Documentation that has been re-exported from a different crateArea: Documentation that has been re-exported from a different crateA-visibilityArea: Visibility / privacyArea: Visibility / privacyC-bugCategory: This is a bug.Category: This is a bug.E-mediumCall for participation: Medium difficulty. Experience needed to fix: Intermediate.Call for participation: Medium difficulty. Experience needed to fix: Intermediate.E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.Call for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.P-mediumMedium priorityMedium priorityT-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.Relevant to the rustdoc team, which will review and decide on the PR/issue.regression-from-stable-to-stablePerformance or correctness regression from one stable version to another.Performance or correctness regression from one stable version to another.