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

Method block_until

crates/test-programs/src/sockets.rs:25–33  ·  view source on GitHub ↗
(&self, timeout: &Pollable)

Source from the content-addressed store, hash-verified

23
24impl Pollable {
25 pub fn block_until(&self, timeout: &Pollable) -> Result<(), ErrorCode> {
26 let ready = poll::poll(&[self, timeout]);
27 assert!(ready.len() > 0);
28 match ready[0] {
29 0 => Ok(()),
30 1 => Err(ErrorCode::Timeout),
31 _ => unreachable!(),
32 }
33 }
34}
35
36impl InputStream {

Callers 10

blocking_write_utilMethod · 0.80
blocking_bindMethod · 0.80
blocking_listenMethod · 0.80
blocking_connectMethod · 0.80
blocking_acceptMethod · 0.80
blocking_check_sendMethod · 0.80
blocking_receiveMethod · 0.80
blocking_finishMethod · 0.80
blocking_close_outputMethod · 0.80

Calls 2

OkFunction · 0.85
pollFunction · 0.50

Tested by

no test coverage detected