建立四模块 CMake 骨架与 line1 样例。

- compiler / vm 空静态库,host 可执行打印版本
- 顶层解开 add_subdirectory,tests 接入 CTest(host_version 通过)
- examples/line1 落地 project.toml 与三个 .st
- Types.h 注释补饱和规则,与 Doc/isa 一致
- .gitignore 忽略 Doc/会话记录.md
This commit is contained in:
2026-08-19 10:09:27 +08:00
parent ff244888c3
commit 9a35a881d1
14 changed files with 135 additions and 4 deletions
+13
View File
@@ -0,0 +1,13 @@
# CMake最低版本
cmake_minimum_required(VERSION 3.21)
# 工程名、版本号、工程描述
project(Compiler
VERSION 0.1
DESCRIPTION "ST / toml 编译器")
include_directories(./include)
# 词法、语法、符号表、类型检查、codegen、链接都留在 compiler 一个库里
add_library(compiler STATIC
./src/Lexer.cpp)