Skip to content

Commit e8cf01b

Browse files
authored
Rollup merge of rust-lang#58589 - matklad:remove-hack, r=petrochenkov
cleanup macro after 2018 transition We can now use `?`
2 parents bb36117 + 65622e3 commit e8cf01b

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

src/libsyntax/ext/expand.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,8 @@ macro_rules! ast_fragments {
3636
(
3737
$($Kind:ident($AstTy:ty) {
3838
$kind_name:expr;
39-
// FIXME: HACK: this should be `$(one ...)?` and `$(many ...)?` but `?` macro
40-
// repetition was removed from 2015 edition in #51587 because of ambiguities.
41-
$(one fn $mut_visit_ast:ident; fn $visit_ast:ident;)*
42-
$(many fn $flat_map_ast_elt:ident; fn $visit_ast_elt:ident;)*
39+
$(one fn $mut_visit_ast:ident; fn $visit_ast:ident;)?
40+
$(many fn $flat_map_ast_elt:ident; fn $visit_ast_elt:ident;)?
4341
fn $make_ast:ident;
4442
})*
4543
) => {

0 commit comments

Comments
 (0)