From 71b10c1c765196a771ce05216395d6b78892a735 Mon Sep 17 00:00:00 2001 From: Quinn Stephens Date: Sun, 3 Nov 2024 16:53:16 -0500 Subject: [compiler] More small refactoring Signed-off-by: Quinn Stephens --- compiler/lexer/lexer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'compiler/lexer') diff --git a/compiler/lexer/lexer.c b/compiler/lexer/lexer.c index 06f7e89..2eaa067 100644 --- a/compiler/lexer/lexer.c +++ b/compiler/lexer/lexer.c @@ -103,7 +103,7 @@ lex_oper(struct lexer *ctx, struct token *tok) if (ctx->pos[1] == '>') { tok->kind = TK_ARROW; tok->len = 2; - } if (ctx->pos[1] == '-') { + } else if (ctx->pos[1] == '-') { tok->kind = TK_MINUS_MINUS; tok->len = 2; } else if (ctx->pos[1] == '=') { -- cgit v1.2.3