Index: src/wasm/wasm-module.h |
diff --git a/src/wasm/wasm-module.h b/src/wasm/wasm-module.h |
index 80cd98fa82663ed6d689896f818debf7f7fa75d7..8cf5501efb0274afa7018c2964e8001c8a36c390 100644 |
--- a/src/wasm/wasm-module.h |
+++ b/src/wasm/wasm-module.h |
@@ -442,13 +442,14 @@ class WasmCompiledModule : public FixedArray { |
return handle(WasmCompiledModule::cast(*ret)); |
} |
- Handle<WasmCompiledModule> Clone(Isolate* isolate) { |
- Handle<WasmCompiledModule> ret = handle(WasmCompiledModule::cast( |
- *isolate->factory()->CopyFixedArray(handle(this)))); |
+ static Handle<WasmCompiledModule> Clone(Isolate* isolate, |
+ Handle<WasmCompiledModule> module) { |
+ Handle<WasmCompiledModule> ret = Handle<WasmCompiledModule>::cast( |
+ isolate->factory()->CopyFixedArray(module)); |
Handle<HeapNumber> number = |
isolate->factory()->NewHeapNumber(0.0, MUTABLE, TENURED); |
ret->set(kID_mem_size, *number); |
- ret->set_mem_size(mem_size()); |
+ ret->set_mem_size(module->mem_size()); |
return ret; |
} |