Function gcore::msg::signal_from
source · pub fn signal_from() -> Result<MessageId>
Expand description
Get an identifier of the message which issued a signal.
The Gear program processes the signal using the handle_signal
function. Therefore, a program should call this function to obtain the
original message identifier which issued a signal.
§Examples
use gcore::msg;
#[no_mangle]
extern "C" fn handle_signal() {
let erroneous_message = msg::signal_from().unwrap();
}