]> git.lizzy.rs Git - rust.git/blob - tests/ui/macros/macro-doc-comments.rs
Rollup merge of #106244 - atouchet:readme3, r=workingjubilee
[rust.git] / tests / ui / macros / macro-doc-comments.rs
1 // run-pass
2 #![allow(non_snake_case)]
3
4 macro_rules! doc {
5     (
6         $(#[$outer:meta])*
7         mod $i:ident {
8             $(#![$inner:meta])*
9         }
10     ) =>
11     (
12         $(#[$outer])*
13         pub mod $i {
14             $(#![$inner])*
15         }
16     )
17 }
18
19 doc! {
20     /// Outer doc
21     mod Foo {
22         //! Inner doc
23     }
24 }
25
26 fn main() { }