aboutsummaryrefslogtreecommitdiff
path: root/src/parser/event_parser/grammar/expressions.rs
blob: f40a3cce2cdb0d2caf1a9cd1b512ef1c9a945a82 (plain)
1
2
3
4
5
6
7
8
9
10
11
use super::*;

pub(super) fn literal(p: &mut Parser) -> bool {
    let literals = [
        TRUE_KW, FALSE_KW,
        INT_NUMBER, FLOAT_NUMBER,
        BYTE, CHAR,
        STRING, RAW_STRING, BYTE_STRING, RAW_BYTE_STRING,
    ];
    node_if(p, AnyOf(&literals), LITERAL, |_| ())
}