Admin
|
d4e2c1ae7c
|
实现 12.4 词法:25 关键字、小写折叠、TIME 字面量、lex error。
- Lexer.h/cpp:关键字表(大小写不敏感折小写)、(* *) 注释不嵌套、整数/T# 段式字面量、最长匹配符号
- token 带 source_file + 行列(起始位置,修了消费后行列的偏差)
- lexer_test:75 断言(line1 三文件 token 流 21/34/27、大小写、符号、注释、行列、5 类负例)
- Doc/compiler/词法.md:设计文档 + 执行计划
|
2026-08-21 10:51:45 +08:00 |
|
Admin
|
c076c25368
|
实现 12.3 toml 读取:schema 校验、文件集合、工程哈希。
- Project.h/cpp:toml++ 解析 + 字段白名单(未知键带行号报错)、name/entry/cycle_limit/dt_ms/files.st 必填、io 条目完整性、entry 必须 program MAIN
- compile_files:files.st ∪ gvl.file 去重;compute_project_hash:路径排序后 FNV-1a 64 增量,缺文件报 file missing
- STCompiler <project.toml>:打印文件列表与哈希,失败退出码 1,--help
- compiler 私有链接 toml++ v3.4.0;测试固化 compiler_toml(35 断言,line1 哈希冻结 0xc3fe4ae74ad45900)
|
2026-08-21 00:32:53 +08:00 |
|
Admin
|
dd7f7bcba7
|
双可执行落地:STCompiler 与 BytecodeExecutor。
- STCompiler 入口在 compiler/src/main.cpp,链 compiler+isa
- host/ 改名 executor/,BytecodeExecutor 链 vm+isa 不链 compiler
- compiler/vm 补 PUBLIC 链 isa;顶层加入 executor
- CTest:版本冒烟 2 例 + isa_roundtrip(89 断言),3/3 通过
|
2026-08-19 14:40:44 +08:00 |
|
Admin
|
9a35a881d1
|
建立四模块 CMake 骨架与 line1 样例。
- compiler / vm 空静态库,host 可执行打印版本
- 顶层解开 add_subdirectory,tests 接入 CTest(host_version 通过)
- examples/line1 落地 project.toml 与三个 .st
- Types.h 注释补饱和规则,与 Doc/isa 一致
- .gitignore 忽略 Doc/会话记录.md
|
2026-08-19 10:09:27 +08:00 |
|