調用與構建 / 工具鏈

工具鏈

LSP 伺服器

aero --lsp 啓動 JSON-RPC 2.0 LSP 伺服器(stdin/stdout),提供:

  • 診斷
  • 代碼補全
  • go-to-definition
  • hover
  • 配套 VS Code 插件(aero-lang-vscode,離線 .vsix 安裝,含語法高亮 + LSP)。

    aero fmt

    rustfmt 風格格式化:

    aero fmt main.aero            # 格式化
    aero fmt main.aero --check    # 只校驗,不寫回
    aero fmt main.aero --width 100 --indent 4

    aero clippy(100+ 規則)

    靜態檢查,按類別分:Naming / Correctness / Style / Complexity / Perf / Pedantic,嚴重級別 Error / Warning / Style / Note。

    規則示例:

  • Naming:fn_non_snake_case、var_non_snake_case、struct_non_upper_camel、const_non_screaming_snake
  • Correctness:division_by_zero、float_equality、same_then_else、unreachable_after_return、infinite_loop_no_break
  • 其餘 Style / Complexity / Perf / Pedantic 規則若干
  • aero clippy main.aero

    aero cov 覆蓋率

    插樁每條語句 → 運行 → 輸出逐行命中數與總覆蓋率百分比(僅統計用户源碼)。

    Aero 文档 · 基于 Aero 1.2.0 文档整理 · MIT
    SereinTeam