Rollup merge of #58697 - taiki-e:question-in-macros, r=Centril

Use ? in some macros
This commit is contained in:
Mazdak Farrokhzad
2019-02-25 03:18:04 +01:00
committed by GitHub
10 changed files with 29 additions and 29 deletions

View File

@@ -431,7 +431,7 @@ mod test {
}
macro_rules! dummy_meta_item_list {
($name:ident, [$($list:ident),* $(,)*]) => {
($name:ident, [$($list:ident),* $(,)?]) => {
MetaItem {
ident: Path::from_ident(Ident::from_str(stringify!($name))),
node: MetaItemKind::List(vec![
@@ -445,7 +445,7 @@ mod test {
}
};
($name:ident, [$($list:expr),* $(,)*]) => {
($name:ident, [$($list:expr),* $(,)?]) => {
MetaItem {
ident: Path::from_ident(Ident::from_str(stringify!($name))),
node: MetaItemKind::List(vec![