aboutsummaryrefslogtreecommitdiff
path: root/lib/Lexer/Lexer.cc
diff options
context:
space:
mode:
author_ov4 <ov4@ov4.org>2026-10-16 10:09:47 +0000
committer_ov4 <ov4@ov4.org>2026-10-16 10:09:47 +0000
commite2c65706e61be09ddb7eeb28cd1957acd4317bcf (patch)
tree15447a03d67d395a722c5be3f0b05bc9f197197a /lib/Lexer/Lexer.cc
parent45c9d37eb27d204a6202b33cb37e890af0171357 (diff)
feat(constants): implement literal constants with lexical scope
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Diffstat (limited to 'lib/Lexer/Lexer.cc')
-rw-r--r--lib/Lexer/Lexer.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/Lexer/Lexer.cc b/lib/Lexer/Lexer.cc
index fcc9a40..59247cf 100644
--- a/lib/Lexer/Lexer.cc
+++ b/lib/Lexer/Lexer.cc
@@ -70,6 +70,7 @@ int Lexer::readToken() {
while (isalnum((LastChar = Input.get())) || LastChar == '_')
IdentifierStr += static_cast<char>(LastChar);
+ if (IdentifierStr == "CONSTANT") return tok_constant;
if (IdentifierStr == "DECLARE") return tok_declare;
if (IdentifierStr == "INTEGER") return tok_integer_kw;
if (IdentifierStr == "BOOLEAN") return tok_boolean_kw;