1
Fork 0

rustdoc: Treat decl macros like other items

This commit is contained in:
León Orell Valerian Liehr 2024-10-29 02:34:25 +01:00
parent 143ce0920a
commit 9016711bf1
No known key found for this signature in database
GPG key ID: D17A07215F68E713
9 changed files with 31 additions and 102 deletions

View file

@ -3,29 +3,17 @@
#![crate_name = "foo"]
//@ has 'foo/macro.todo.html'
//@ has - '//span[@class="macro"]' 'macro_rules!'
//@ hasraw - ' todo {'
//@ hasraw - '{ () => { ... }; ($('
//@ has - '//span[@class="macro-nonterminal"]' '$'
//@ has - '//span[@class="macro-nonterminal"]' 'arg'
//@ hasraw - ':tt)+'
//@ hasraw - ') => { ... }; }'
//@ has 'foo/macro.todo.html' '//pre' 'macro_rules! todo { \
// () => { ... }; \
// ($($arg:tt)+) => { ... }; \
// }'
pub use std::todo;
mod mod1 {
//@ has 'foo/macro.macro1.html'
//@ hasraw - 'macro_rules!'
//@ hasraw - 'macro1'
//@ hasraw - '{ () => { ... }; ($('
//@ has - '//span[@class="macro-nonterminal"]' '$'
//@ has - '//span[@class="macro-nonterminal"]' 'arg'
//@ hasraw - ':'
//@ hasraw - 'expr'
//@ hasraw - '),'
//@ hasraw - '+'
//@ hasraw - ') => { ... }; }'
//@ has 'foo/macro.macro1.html' '//pre' 'macro_rules! macro1 { \
// () => { ... }; \
// ($($arg:expr),+) => { ... }; \
// }'
#[macro_export]
macro_rules! macro1 {
() => {};