4 bool preprocess(const char *filename)
7 lex_file *lex = lex_open(filename);
8 lex->flags.preprocessing = true;
15 else if (tok >= TOKEN_START && tok <= TOKEN_FATAL)
16 printf("%s: ", _tokennames[tok - TOKEN_START]);
18 printf("TOKEN: '%c'", tok);
19 if (tok == TOKEN_WHITE)
20 printf(">>%s<<\n", lex->tok.value);
26 else if (tok >= TOKEN_START && tok < TOKEN_EOF)
27 printf("%s", lex->tok.value);
28 else if (tok < TOKEN_START)
29 printf("%c", tok); /* these are characters */
31 } while (tok < TOKEN_EOF);