This repository was archived by the owner on May 28, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +19
-2
lines changed Expand file tree Collapse file tree 2 files changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -2333,15 +2333,16 @@ impl Clean<Item> for (&hir::MacroDef<'_>, Option<Ident>) {
23332333 // This code currently assumes that there will only be one or zero matchers, as syntax
23342334 // for multiple is not currently defined.
23352335 format ! (
2336- "pub macro {}({}) {{\n \t ...\n }}" ,
2336+ "{}macro {}{} {{\n \t ...\n }}" ,
2337+ item. vis. clean( cx) . print_with_space( ) ,
23372338 name,
23382339 matchers. iter( ) . map( |span| span. to_src( cx) ) . collect:: <String >( ) ,
23392340 )
23402341 } ;
23412342
23422343 Item :: from_hir_id_and_parts (
23432344 item. hir_id ,
2344- Some ( name. clean ( cx ) ) ,
2345+ Some ( name) ,
23452346 MacroItem ( Macro { source, imported_from : None } ) ,
23462347 cx,
23472348 )
Original file line number Diff line number Diff line change 1+
2+ #![ feature( decl_macro) ]
3+
4+ // @has macros_2/macro.my_macro.html //pre 'pub macro my_macro() {'
5+ // @has - //pre '...'
6+ // @has - //pre '}'
7+ pub macro my_macro ( ) {
8+
9+ }
10+
11+ // @has macros_2/macro.my_macro_2.html //pre 'pub macro my_macro_2($($tok:tt)*) {'
12+ // @has - //pre '...'
13+ // @has - //pre '}'
14+ pub macro my_macro_2( $( $tok: tt) * ) {
15+
16+ }
You can’t perform that action at this time.
0 commit comments