frontend: Add handling for comments

This commit introduces a comment token which is to be ignored by the
parser.

Signed-off-by: Ian Moffett <ian@mirocom.org>
This commit is contained in:
2026-03-25 19:45:51 -04:00
parent b769c1cdeb
commit 08f07e474e
3 changed files with 24 additions and 0 deletions

View File

@@ -38,6 +38,7 @@ static const char *toktab[] = {
[TT_NAME] = symtok("name"),
[TT_NEWLINE] = symtok("newline"),
[TT_SHELLBLOCK] = symtok("shellblock"),
[TT_COMMENT] = symtok("comment"),
[TT_CC] = qtok(".cc"),
[TT_LD] = qtok(".ld"),
[TT_COLON] = qtok(":")