From 0f5304001cc17e14123e3c06c66529926a275da7 Mon Sep 17 00:00:00 2001 From: PuqiAR Date: Sat, 4 Jul 2026 19:32:01 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E6=B3=A8=E9=87=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Parser/ParserTest.cpp | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/Parser/ParserTest.cpp b/src/Parser/ParserTest.cpp index de096d0..7e9845c 100644 --- a/src/Parser/ParserTest.cpp +++ b/src/Parser/ParserTest.cpp @@ -5,18 +5,17 @@ int main() { using namespace Fig; - String fileName = "test.fig"; + String fileName = "[memory]"; String filePath = - "T:/Files/Maker/Code/MyCodingLanguage/The Fig Project/Fig/" + fileName; + "System" + fileName; SourceManager srcManager(filePath); - String source = srcManager.Read(); - if (!srcManager.read) - { - std::cerr << "Couldn't read file: " << filePath << '\n'; - return 1; - } + String source = R"( + var a = 10; + var a: Int; + var a := 200 * 30 + 2; + )"; Lexer lexer(source, fileName);