安装 SYX
仅仅运行 SYX 程序不需要先装 Rust。发布版提供预编译的 syx 二进制。从源码构建工具链需要 Rust 1.85+;完整原生(LLVM)工具链还需要本地 LLVM。
方案 A —— 预编译发布版(推荐)
- 打开最新发布页:github.com/synvek/syx/releases/latest
- 下载对应操作系统 / 架构的压缩包
- 将
syx放入PATH - 验证:
bash
syx --version
syx run path/to/hello.sy方案 B —— 从源码构建
bash
git clone https://github.com/synvek/syx.git
cd syx
cargo build --release -p syx-cli
./target/release/syx run examples/hello.sy可选安装到 Cargo bin 目录:
bash
cargo install --path crates/syx-cli原生 AOT(syx build --native)需要 full-native / LLVM 特性集 —— 细节见快速指南。
编辑器支持
安装 VS Code 的 SYX Language 扩展(TextMate + LSP + DAP)。见编辑器与 VS Code。
下一步
- 源文件后缀 (.sy) 与
syx.toml - 后端 —— VM、LLVM、Wasm
- 语言指南中的入门