Skip to content

Reorg and update attributes#537

Merged
Centril merged 4 commits into
rust-lang:masterfrom
ehuss:attribute-reorg-syntax
Mar 17, 2019
Merged

Reorg and update attributes#537
Centril merged 4 commits into
rust-lang:masterfrom
ehuss:attribute-reorg-syntax

Conversation

@ehuss
Copy link
Copy Markdown
Contributor

@ehuss ehuss commented Mar 15, 2019

  • Move "Attributes" out of the "Items" chapter.
  • Move each attribute out of attributes.md, scattered to various locations throughout the reference, including a few new dedicated pages. Each attribute gets a dedicated section to make it easier to link to, and enough room to fully document.
  • See attributes.md for the consolidated built-in index.
  • Document the syntax for the inputs of every built-in attribute.
  • Minor updates and additions to various attributes.
  • Removed no_start, it is no longer used. Removed when runtime/green threads were removed Finish runtime removal rust#18967.

Things reserved for future PRs:

  • Expanding individual attributes. Some are too brief or slightly wrong.
  • Documenting the remaining undocumented attributes.
  • Finish the "Attributes on" sections to specify where each attribute may be used.

Some of the new locations seem a little awkward or arbitrary, but I couldn't think of better choices. I wanted to open this up to start getting feedback.

This is written assuming rust-lang/rust#58899 will get merged. Also, some attributes are not very strict about validating their inputs (for example, link ignores any unknown field). I documented with what I think they are intended, not what they actually accept.

Closes #534

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants