VM global_env sync + isomorphic nav store primitives
Reverse hook syncs VM GLOBAL_SET mutations back to global_env so CEK reads see JIT-written values. Isomorphic nav: store primitives, event-bridge, client? predicate. Browser JS and bytecode rebuilt. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -303,7 +303,11 @@ and run vm =
|
||||
in find_env env
|
||||
| None -> false
|
||||
in
|
||||
if not written then Hashtbl.replace vm.globals name (peek vm)
|
||||
if not written then begin
|
||||
let v = peek vm in
|
||||
Hashtbl.replace vm.globals name v;
|
||||
(match !Sx_types._vm_global_set_hook with Some f -> f name v | None -> ())
|
||||
end
|
||||
|
||||
(* ---- Control flow ---- *)
|
||||
| 32 (* OP_JUMP *) ->
|
||||
|
||||
Reference in New Issue
Block a user