pub fn wake(message_id: MessageId) -> Result<()>
Expand description
Resume previously paused message handling.
Suppose a message has been paused using the wait
function. In that case,
it is possible to continue its execution by calling this function.
message_id
specifies a particular message to be taken out of the waiting
queue and put into the processing queue.
§Examples
use gcore::{exec, msg, MessageId};
static mut MSG_ID: MessageId = MessageId::zero();
#[no_mangle]
extern "C" fn init() {
unsafe { MSG_ID = msg::id() };
exec::wait();
}
#[no_mangle]
extern "C" fn handle() {
exec::wake(unsafe { MSG_ID }).expect("Unable to wake");
}