Skip to content

Attribute docs deprecated , warn, allow, cfg, deny, and forbid #158244

Open
kantnero wants to merge 4 commits into
rust-lang:mainfrom
kantnero:attribute-docs-deprecated-warn
Open

Attribute docs deprecated , warn, allow, cfg, deny, and forbid #158244
kantnero wants to merge 4 commits into
rust-lang:mainfrom
kantnero:attribute-docs-deprecated-warn

Conversation

@kantnero

@kantnero kantnero commented Jun 22, 2026

Copy link
Copy Markdown

View all comments

Added documentation for built-in deprecated , warn, allow, cfg, deny, and forbid attributes using the #[doc(attribute = "...")] mechanism.

Part of #157604

@rustbot r? @GuillaumeGomez
cc @fmease
cc @mejrs

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Jun 22, 2026
@rustbot

rustbot commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

Thanks for the pull request, and welcome! The Rust Project is excited to review your changes, and you should hear from @GuillaumeGomez (or someone else) some time within the next two weeks.

Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (S-waiting-on-review and S-waiting-on-author) stays updated, invoking these commands when appropriate:

  • @rustbot author: the review is finished, PR author should check the comments and take action accordingly
  • @rustbot review: the author is ready for a review, this PR will be queued again in the reviewer's queue

Comment thread library/std/src/attribute_docs.rs
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs
Comment thread library/std/src/attribute_docs.rs
Comment thread library/std/src/attribute_docs.rs
Comment thread library/std/src/attribute_docs.rs
@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 22, 2026
@rustbot

rustbot commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

Reminder, once the PR becomes ready for a review, use @rustbot ready.

@kantnero kantnero changed the title Attribute docs deprecated and warn Attribute docs deprecated , warn, allow, cfg, deny, and forbid Jun 22, 2026
@kantnero

Copy link
Copy Markdown
Author

@GuillaumeGomez I have addressed it. Please have a look at it

Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
@kantnero kantnero requested a review from GuillaumeGomez June 22, 2026 23:41
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jun 22, 2026
… attribute

Signed-off-by: Emmanuel Ugwu <emmanuelugwu121@gmail.com>
@kantnero kantnero force-pushed the attribute-docs-deprecated-warn branch from 20a1e85 to e9b4cfc Compare June 22, 2026 23:55
@rustbot

rustbot commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed.

Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers.

Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs
@fmease

fmease commented Jun 23, 2026

Copy link
Copy Markdown
Member

cc @rust-lang/lang-docs

Comment thread library/std/src/attribute_docs.rs
Comment thread library/std/src/attribute_docs.rs Outdated
Comment on lines +272 to +273
/// `since`: the version since when the item is deprecated.
/// `note`: the reason why an item is deprecated.

@GuillaumeGomez GuillaumeGomez Jun 23, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
/// `since`: the version since when the item is deprecated.
/// `note`: the reason why an item is deprecated.
/// * `since`: the version since when the item is deprecated.
/// * `note`: the reason why an item is deprecated.

View changes since the review

Comment thread library/std/src/attribute_docs.rs
Comment thread library/std/src/attribute_docs.rs
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs Outdated
Comment thread library/std/src/attribute_docs.rs
Comment thread library/std/src/attribute_docs.rs
kantnero added 2 commits June 23, 2026 15:45
Signed-off-by: Emmanuel Ugwu <emmanuelugwu121@gmail.com>
Signed-off-by: Emmanuel Ugwu <emmanuelugwu121@gmail.com>
@kantnero kantnero requested a review from GuillaumeGomez June 23, 2026 14:53
@rust-log-analyzer

This comment has been minimized.

Signed-off-by: Emmanuel Ugwu <emmanuelugwu121@gmail.com>
@kantnero kantnero force-pushed the attribute-docs-deprecated-warn branch from 4881c0f to f10d106 Compare June 23, 2026 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants