From fa02225c5ae8b704408769c70bb47101042762b8 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Sun, 20 Feb 2022 18:48:30 +0100 Subject: Haskell ftw --- src/lint.c | 21 --------------------- 1 file changed, 21 deletions(-) delete mode 100644 src/lint.c (limited to 'src/lint.c') 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 - -#include -#include -#include - -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"); -} -- cgit v1.2.3