40/40 VM tests pass, auto-compile disabled until full aser compilation
All VM tests green: closures with shared mutable upvalues, map/filter/ for-each via CALL_PRIM, recursive functions, nested closures. Auto-compile disabled: replacing individual Lambdas with NativeFn VM wrappers changes how the CEK dispatches calls, causing scope errors when mixed CEK+VM execution hits aser-expand-component. The fix is compiling the ENTIRE aser render path to run on the VM — no mixing. The VM infrastructure is complete and tested. Next step: compile adapter-sx.sx as a whole module, run the aser on the VM. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -265,9 +265,12 @@ class OcamlBridge:
|
||||
_logger.info("Loaded %d definitions from .sx files into OCaml kernel (%d skipped)",
|
||||
count, skipped)
|
||||
|
||||
# VM auto-compile: ready when compiler handles all SX features.
|
||||
# Currently 6/117 compile; fallback fails on closure scope vars.
|
||||
# await self._send('(vm-compile)')
|
||||
# VM bytecode infrastructure ready. Auto-compile disabled:
|
||||
# compiled NativeFn wrappers change CEK dispatch behavior
|
||||
# causing scope errors in aser-expand-component. The VM
|
||||
# tests (40/40) verify correctness in isolation.
|
||||
# Enable after: full aser adapter compilation so the ENTIRE
|
||||
# render path runs on the VM, not mixed CEK+VM.
|
||||
except Exception as e:
|
||||
_logger.error("Failed to load .sx files into OCaml kernel: %s", e)
|
||||
self._components_loaded = False # retry next time
|
||||
|
||||
Reference in New Issue
Block a user