Adjust code generator for brackets in Token definition

This commit is contained in:
David Tolnay 2020-10-24 11:17:25 -07:00
parent 2d529603a2
commit f9f55521a8
No known key found for this signature in database
GPG Key ID: F9BA143B95FF6D82

View File

@ -416,7 +416,7 @@ mod parsing {
tokens.insert("await".to_owned(), "Await".to_owned());
} else {
let pattern;
parenthesized!(pattern in rules);
bracketed!(pattern in rules);
let token = pattern.parse::<TokenStream>()?.to_string();
rules.parse::<Token![=>]>()?;
let expansion;