aboutsummaryrefslogtreecommitdiff
path: root/src/parser/grammar/items/traits.rs
blob: 9961a88feeeb133084f65e62af33a424fe86ca31 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use super::*;

pub(super) fn trait_item(p: &mut Parser) {
    assert!(p.at(TRAIT_KW));
    p.bump();
    name(p);
    p.expect(L_CURLY);
    p.expect(R_CURLY);
}

pub(super) fn impl_item(p: &mut Parser) {
    assert!(p.at(IMPL_KW));
    p.bump();
    p.expect(IDENT);
    p.expect(L_CURLY);
    p.expect(R_CURLY);
}