~starkingdoms/starkingdoms

ref: 46218c06a96bcafb08cd18349edc8a5b7e451604 starkingdoms/kabel/src/macros.rs -rw-r--r-- 323 bytes
46218c06 — ghostlyzsh calculator parser kabel 1 year, 4 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
#[macro_export]
macro_rules! token {
    ($self:expr, $token:expr) => {
        crate::lexer::Token {
            line: $self.line,
            line_start: $self.line_start,
            column: $self.column,
            start: $self.start,
            end: $self.current,
            token_type: $token,
        }
    };
}