Skip to content

Commit fef3e03

Browse files
committed
Add repetition example
1 parent 9423cdb commit fef3e03

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

tests/source/macro_rules.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
macro_rules! m {
2-
($expr :expr, $func : ident) => {
2+
($expr :expr, $( $func : ident ) * ) => {
33
{
44
let x = $expr;
55
$func (

tests/target/macro_rules.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
macro_rules! m {
2-
($expr: expr, $func: ident) => {{
2+
($expr: expr, $($func: ident)*) => {{
33
let x = $expr;
44
$func(x)
55
}};

0 commit comments

Comments
 (0)