Function wait [src]
Block's the callers thread until the ResetEvent is set().
This is effectively a more efficient version of while (!isSet()) {}.
The memory accesses before the set() can be said to happen before wait() returns.
Prototype
pub fn wait(self: *ResetEvent) void
Parameters
self: *ResetEvent
Source
pub fn wait(self: *ResetEvent) void {
self.impl.wait(null) catch |err| switch (err) {
error.Timeout => unreachable, // no timeout provided so we shouldn't have timed-out
};
}