Index: src/frames.cc |
diff --git a/src/frames.cc b/src/frames.cc |
index 5ecffaf7b10f1b8e6dcba021a98c901e3460c6d4..b8abe823f53a946bd5c64d4f86d363d778957930 100644 |
--- a/src/frames.cc |
+++ b/src/frames.cc |
@@ -1532,9 +1532,12 @@ Script* WasmFrame::script() const { |
int WasmFrame::position() const { |
int position = StandardFrame::position(); |
if (wasm::WasmIsAsmJs(wasm_instance(), isolate())) { |
- Handle<JSObject> instance(JSObject::cast(wasm_instance()), isolate()); |
- position = |
- wasm::GetAsmWasmSourcePosition(instance, function_index(), position); |
+ Handle<WasmCompiledModule> compiled_module( |
+ WasmInstanceObject::cast(wasm_instance())->get_compiled_module(), |
+ isolate()); |
+ DCHECK_LE(0, position); |
+ position = WasmCompiledModule::GetAsmJsSourcePosition( |
+ compiled_module, function_index(), static_cast<uint32_t>(position)); |
} |
return position; |
} |