(&self, _tid: Tid, callback: &mut dyn FnMut(u64))
| 351 | |
| 352 | impl<'a> Wasm for Debugger<'a> { |
| 353 | fn wasm_call_stack(&self, _tid: Tid, callback: &mut dyn FnMut(u64)) -> Result<(), Self::Error> { |
| 354 | let debuggee = self.debuggee; |
| 355 | for (i, f) in self.frame_cache.iter().enumerate() { |
| 356 | // For non-innermost frames, report the return address |
| 357 | // (the instruction after the call) rather than the call |
| 358 | // instruction's PC. This matches the standard debugger |
| 359 | // convention and is needed for LLDB's `finish` command |
| 360 | // to set a breakpoint at the right address. |
| 361 | let pc = if i > 0 { |
| 362 | self.addr_space |
| 363 | .frame_to_return_addr(f, debuggee) |
| 364 | .unwrap_or_else(|| self.addr_space.frame_to_pc(f, debuggee)) |
| 365 | } else { |
| 366 | self.addr_space.frame_to_pc(f, debuggee) |
| 367 | }; |
| 368 | callback(pc.as_raw()); |
| 369 | } |
| 370 | Ok(()) |
| 371 | } |
| 372 | |
| 373 | fn read_wasm_local( |
| 374 | &self, |
nothing calls this directly
no test coverage detected