1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16  | #include <stdio.h>
#include "lexer.h"
int
main()
{
    setLexerIn(stdin, 0);
    while (getToken() != EOI) {
        printf("%zu.%zu-%zu.%zu: %s '%s' '%s'\n",
               token.loc.begin.line, token.loc.begin.col,
               token.loc.end.line, token.loc.end.col,
               strTokenKind(token.kind), token.val.cstr,
               token.processedVal.cstr);
    }
}
 |