From fc0a9e266b9d663b1eeca3963495c68ca3384be2 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Sat, 10 Feb 2018 14:00:23 +0300 Subject: G: introduce names --- src/parser/grammar/items/mod.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/parser/grammar/items') diff --git a/src/parser/grammar/items/mod.rs b/src/parser/grammar/items/mod.rs index ffe86fa97..d671568b1 100644 --- a/src/parser/grammar/items/mod.rs +++ b/src/parser/grammar/items/mod.rs @@ -196,8 +196,9 @@ fn extern_crate_item(p: &mut Parser) { p.bump(); assert!(p.at(CRATE_KW)); p.bump(); - - p.expect(IDENT) && alias(p) && p.expect(SEMI); + name(p); + alias(p); + p.expect(SEMI); } fn extern_block(p: &mut Parser) { -- cgit v1.2.3