diff options
Diffstat (limited to 'src/lint.c')
-rw-r--r-- | src/lint.c | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/src/lint.c b/src/lint.c deleted file mode 100644 index 7c2e9da..0000000 --- a/src/lint.c +++ /dev/null @@ -1,21 +0,0 @@ -#include <stddef.h> - -#include <lint.h> -#include <log.h> -#include <tokenize.h> - -void lint(struct ctx *ctx) -{ - // Lint parens - int parens = 0; - for (size_t i = 1; i < ctx->token_count; i++) { - struct token *token = &ctx->tokens[i]; - if (token->type == LPAREN) - parens++; - else if (token->type == RPAREN) - parens--; - } - - if (parens != 0) - errln(&ctx->location, "Invalid parens balance"); -} |