refactor: 动态编译改经 CompilerService 注入,oxide_vm 去编译器依赖

This commit is contained in:
2026-10-08 05:51:58 +00:00
parent 66735f802f
commit 4f9b6ab444
94 changed files with 459 additions and 67 deletions
+6
View File
@@ -68,6 +68,9 @@ impl Vm {
active_immutables: std::ptr::slice_from_raw_parts(std::ptr::null(), 0),
frames: smallvec::SmallVec::new(),
kernel_core: core,
// 缺省 no-op 编译服务:动态编译返 Err,生产 entry points 与
// 动态编译测试经 set_compiler_service 注入真实实现。
compiler: Arc::new(crate::vm::NoopCompilerService),
realm: Arc::new(Realm {
realm_id,
session: RefCell::new(session),
@@ -221,6 +224,9 @@ impl Vm {
active_immutables: std::ptr::slice_from_raw_parts(std::ptr::null(), 0),
frames: smallvec::SmallVec::new(),
kernel_core: core,
// 缺省 no-op 编译服务:动态编译返 Err,生产 entry points 与
// 动态编译测试经 set_compiler_service 注入真实实现。
compiler: Arc::new(crate::vm::NoopCompilerService),
realm: Arc::new(Realm {
realm_id,
session: RefCell::new(session),