Recompile all 26 .sxbc with define-library wrappers + fix eval/JIT

All 26 browser modules recompiled with define-library/import forms.
Compilation works without vm-compile-adapter (JIT pre-compilation
hangs with library wrappers in some JIT paths — skipped for now,
CEK compilation is ~34s total).

Key fixes:
- eval command: import-aware loop that handles define-library/import
  locally without touching the Python bridge pipe (avoids deadlock)
- compile-modules.js: skip vm-compile-adapter, bump timeout

2621/2621 OCaml tests passing.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-04 00:08:00 +00:00
parent ac772ac357
commit 7b4c918773
48 changed files with 8884 additions and 5899 deletions

View File

@@ -1,4 +1,30 @@
;; Assert condition is truthy, error with message
(define-library (sx harness)
(export
assert
assert=
default-platform
make-harness
harness-reset!
harness-log
harness-get
harness-set!
make-interceptor
install-interceptors
io-calls
io-call-count
io-call-nth
io-call-args
io-call-result
assert-io-called
assert-no-io
assert-io-count
assert-io-args
assert-io-result
assert-state)
(begin
(define assert (fn (condition msg) (when (not condition) (error (or msg "Assertion failed")))))
;; Assert two values are equal
@@ -60,3 +86,9 @@
;; Assert a state key has the expected value
(define assert-state :effects () (fn (session key expected) (let ((actual (harness-get session key))) (assert (equal? actual expected) (str "Expected state " key " to be " (str expected) " but got " (str actual))))))
)) ;; end define-library
;; Re-export to global namespace for backward compatibility
(import (sx harness))