G: use names in traits

This commit is contained in:
Aleksey Kladov 2018-02-10 14:15:04 +03:00
parent c13e6db774
commit fa2131365e
3 changed files with 9 additions and 7 deletions

View file

@ -3,7 +3,7 @@ use super::*;
pub(super) fn trait_item(p: &mut Parser) {
assert!(p.at(TRAIT_KW));
p.bump();
p.expect(IDENT);
name(p);
p.expect(L_CURLY);
p.expect(R_CURLY);
}

View file

@ -3,6 +3,7 @@ FILE@[0; 18)
UNSAFE_KW@[0; 6)
WHITESPACE@[6; 7)
TRAIT_KW@[7; 12)
NAME@[12; 15)
WHITESPACE@[12; 13)
IDENT@[13; 14) "T"
WHITESPACE@[14; 15)

View file

@ -5,6 +5,7 @@ FILE@[0; 23)
AUTO_KW@[7; 11)
WHITESPACE@[11; 12)
TRAIT_KW@[12; 17)
NAME@[17; 20)
WHITESPACE@[17; 18)
IDENT@[18; 19) "T"
WHITESPACE@[19; 20)