From 927e3fc0384c941f9ad313a28768660c3cdb1777 Mon Sep 17 00:00:00 2001 From: _ov4 Date: Sun, 18 Oct 2026 08:04:15 +0000 Subject: feat(driver): add #LIB directive hiding library lines in runtime errors Co-Authored-By: Claude Opus 5.5 --- include/cps/Lexer.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include/cps/Lexer.h') diff --git a/include/cps/Lexer.h b/include/cps/Lexer.h index 1c4723e..588a5fa 100644 --- a/include/cps/Lexer.h +++ b/include/cps/Lexer.h @@ -120,6 +120,8 @@ class Lexer { int CurrentLine = 1; int TokenLine = 1; bool HadError = false; + bool Library = false; + bool LineStart = true; struct TokenData { int Kind, Line; std::string Identifier, String; @@ -145,6 +147,7 @@ public: int peekToken(unsigned Offset = 0); int peekLine(unsigned Offset = 0); int getLine() const { return TokenLine; } + bool isLibrary() const { return Library; } bool hadError() const { return HadError; } }; -- cgit v1.3.1-4-g156e