diff options
Diffstat (limited to 'src/libsyntax/parse')
| -rw-r--r-- | src/libsyntax/parse/parser.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index 5a20c7f40e6..2a80c0a05bf 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -1295,7 +1295,6 @@ impl<'a> Parser<'a> { let (name, node, generics) = if self.eat_keyword(keywords::Type) { let (generics, TyParam {ident, bounds, default, ..}) = self.parse_trait_item_assoc_ty(vec![])?; - self.expect(&token::Semi)?; (ident, TraitItemKind::Type(bounds, default), generics) } else if self.is_const_item() { self.expect_keyword(keywords::Const)?; @@ -4464,6 +4463,7 @@ impl<'a> Parser<'a> { } else { None }; + self.expect(&token::Semi)?; Ok((generics, TyParam { attrs: preceding_attrs.into(), |
