mirror of
https://github.com/rust-lang/rust.git
synced 2025-01-19 11:12:43 +00:00
Add test for #2558
When run against invalid macro definitions, rustfmt should leave them unchanged rather than panic.
This commit is contained in:
parent
e68682f6db
commit
38107192f1
@ -188,3 +188,9 @@ macro_rules! binary {
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
// #2558
|
||||
macro_rules! m {
|
||||
($x:) => {};
|
||||
($($foo:expr)()?) => {};
|
||||
}
|
||||
|
@ -220,3 +220,9 @@ macro_rules! binary {
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
// #2558
|
||||
macro_rules! m {
|
||||
($x:) => {};
|
||||
($($foo:expr)()?) => {};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user