frontend: add token coordinates to print_lex_token output
This commit is contained in:
@@ -9,6 +9,9 @@
|
|||||||
|
|
||||||
extern void print_lex_token(struct ivy_token *tok)
|
extern void print_lex_token(struct ivy_token *tok)
|
||||||
{
|
{
|
||||||
|
printf("[%lu:%lu - %lu:%lu] ", tok->t_start.p_row, tok->t_start.p_col,
|
||||||
|
tok->t_end.p_row, tok->t_end.p_col);
|
||||||
|
|
||||||
switch (tok->t_type) {
|
switch (tok->t_type) {
|
||||||
case IVY_TOK_KEYWORD:
|
case IVY_TOK_KEYWORD:
|
||||||
b_puts("[magenta]");
|
b_puts("[magenta]");
|
||||||
|
|||||||
Reference in New Issue
Block a user