Skip to content

Conversation

@durka
Copy link
Contributor

@durka durka commented Mar 1, 2016

Rearrange and add content to the Macros section to make it more informative and useful.

Changelog:

  • add an example at the beginning
  • remove non-sequitur mention of sep_token and non_special_token
  • fix confusing definition of tt
  • add term "fragment specifier" since that's what designators are called in the book
  • rewrite explanation of lockstep repetition
    • fix incorrect example
    • remove "scare quotes"
  • add discussion of scoping (#[macro_use], #[macro_export], #[macro_reexport], $crate)
  • rebase to remove unrelated changes that snuck in somehow

@rust-highfive
Copy link
Contributor

r? @Manishearth

(rust_highfive has picked a reviewer for you, use r? to override)

Copy link
Member

Choose a reason for hiding this comment

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

do footnotes work in rustdoc?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The same syntax is used elsewhere in the reference.

@durka durka force-pushed the patch-16 branch 3 times, most recently from 98c0144 to cc1b792 Compare March 1, 2016 21:34
durka and others added 2 commits March 3, 2016 12:06
Rearrange and add content to the Macros section to make it more informative and useful.
from the "procedural macros" defined in [compiler plugins][plugin].
`macro_rules` allows users to define syntax extensions in a declarative way.
We call such extensions "`macro_rules!` macros" or simply "macros" — to be
distinguished from the "procedural macros" defined in [compiler plugins][plugin].
Copy link
Contributor

@LeoTestard LeoTestard Jun 1, 2016

Choose a reason for hiding this comment

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

The term ‶macros by example″ has also been used at several places and might be worth mentionning.

@alexcrichton
Copy link
Member

Closing due to inactivity, but feel free to reopen with comments addressed!

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.

5 participants