restore(lang): full lang tree from ff3ef452 (306 files) — compiler, vm, shared, runner, c-abi, etc.\n\n- Restores lang/ directory (files≈306, dirs≈64) as per historical branch with selfhost sources\n- Keeps our recent parser index changes in compiler/* (merged clean by checkout)\n- Unblocks selfhost development and documentation references

This commit is contained in:
nyash-codex
2025-10-31 20:45:46 +09:00
parent dbc285f2b1
commit e5f697eb22
244 changed files with 16915 additions and 47 deletions

View File

@ -0,0 +1,8 @@
#![doc = "Phase 20.13 vm_front guard — define layer responsibilities."]
static box VM_FRONT_GUARD {
name() { return "vm_front" }
allowed_imports() { return ["json", "env"] }
forbidden_imports() { return ["vm_core", "llvm", "plugins", "ffi"] }
}

View File

@ -0,0 +1,26 @@
# vm_front — VM Front EXE (Phase 20.13; optional)
Purpose
- Provide light dispatch hints/normalization prior to VM/LLVM execution.
- Keep semantics in VM/LLVM; vm_front only shapes inputs and rejects invalid cases early.
Responsibilities
- Normalize callee/method hints; produce OK/NOOP/FAIL (short) with exit code.
Notes (AOT / SingleEXE)
- 将来的に単一exeに内蔵AOTされ、同一プロセスで前段整流を行います。
- 開発時は tools/front_exe/vm_front.sh をゲートONで差し替え可能です。
Inputs/Outputs
- Input: small JSON describing callsite/callee
- Output: one-line verdict (OK/NOOP/FAIL) + exit code
ENV (planned; default OFF)
- HAKO_VM_USE_SCRIPT_EXE=1 (alias NYASH_*) — enable vm front EXE
- HAKO_QUIET=1
NonGoals
- No execution, no state, no ABI interaction.
TTL
- Runner-side formatting will migrate here after stabilization.