Skip to content

Commit 1cf11cc

Browse files
committed
Rollup merge of rust-lang#27067 - GuillaumeGomez:patch-1, r=cmr
Now the macro argument list can be finished by a comma (not sure this is correct english...). cc @tamird r? @bluss
2 parents 22aa163 + 6e58043 commit 1cf11cc

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/libsyntax/diagnostics/macros.rs

+6
Original file line numberDiff line numberDiff line change
@@ -63,12 +63,18 @@ macro_rules! fileline_help {
6363
macro_rules! register_diagnostics {
6464
($($code:tt),*) => (
6565
$(register_diagnostic! { $code })*
66+
);
67+
($($code:tt),*,) => (
68+
$(register_diagnostic! { $code })*
6669
)
6770
}
6871

6972
#[macro_export]
7073
macro_rules! register_long_diagnostics {
7174
($($code:tt: $description:tt),*) => (
7275
$(register_diagnostic! { $code, $description })*
76+
);
77+
($($code:tt: $description:tt),*,) => (
78+
$(register_diagnostic! { $code, $description })*
7379
)
7480
}

0 commit comments

Comments
 (0)