MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / wait_for_initial

Method wait_for_initial

crates/debugger/src/lib.rs:313–325  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

311 }
312
313 async fn wait_for_initial(&mut self) -> Result<()> {
314 if let DebuggeeState::Initial = &self.state {
315 // Need to receive and discard first `Paused`.
316 let response = self
317 .out_rx
318 .recv()
319 .await
320 .ok_or_else(|| wasmtime::format_err!("Premature close of debugger channel"))?;
321 assert!(matches!(response, Response::Paused(_)));
322 self.state = DebuggeeState::Paused;
323 }
324 Ok(())
325 }
326
327 /// Run the inner body until the next debug event.
328 ///

Callers 2

runMethod · 0.80
with_storeMethod · 0.80

Calls 1

OkFunction · 0.85

Tested by

no test coverage detected