From 17cec530b0a4d792bde2d37583b6c26e89f9b1bd Mon Sep 17 00:00:00 2001 From: _ov4 Date: Tue, 13 Oct 2026 12:32:03 +0000 Subject: fix: distinguish compiler errors and report compilation termination Co-Authored-By: Claude Fable 5.1 --- lib/Lexer/Lexer.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/Lexer/Lexer.cc') diff --git a/lib/Lexer/Lexer.cc b/lib/Lexer/Lexer.cc index 6299371..4f7f997 100644 --- a/lib/Lexer/Lexer.cc +++ b/lib/Lexer/Lexer.cc @@ -25,7 +25,7 @@ int Lexer::gettok() { if (LastChar == '"') { LastChar = Input.get(); } else { - fprintf(stderr, "Error: Unterminated string literal at line %d\n", CurrentLine); + fprintf(stderr, "error: Unterminated string literal at line %d\n", CurrentLine); HadError = true; } @@ -35,7 +35,7 @@ int Lexer::gettok() { if (LastChar == '\'') { int CharCode = Input.get(); if (CharCode == EOF || CharCode == '\n') { - fprintf(stderr, "Error: Unterminated char literal at line %d\n", CurrentLine); + fprintf(stderr, "error: Unterminated char literal at line %d\n", CurrentLine); HadError = true; CharVal = '?'; StringVal.assign(1, CharVal); @@ -46,7 +46,7 @@ int Lexer::gettok() { int ClosingQuote = Input.get(); if (ClosingQuote != '\'') { - fprintf(stderr, "Error: CHAR literal must contain exactly one character (line %d)\n", CurrentLine); + fprintf(stderr, "error: CHAR literal must contain exactly one character (line %d)\n", CurrentLine); HadError = true; while (ClosingQuote != EOF && ClosingQuote != '\n' && ClosingQuote != '\'') { ClosingQuote = Input.get(); -- cgit v1.3.1-4-g156e