"__rust_start_panic" | "panic_impl" => {
return err!(MachineError("the evaluated program panicked".to_string()));
}
- "exit" => {
+ "exit" | "ExitProcess" => {
+ // it's really u32 for ExitProcess, but we have to put it into the `Exit` error variant anyway
let code = this.read_scalar(args[0])?.to_i32()?;
return err!(Exit(code));
}
- "ExitProcess" => {
- let code = this.read_scalar(args[0])?.to_u32()?;
- return err!(Exit(code as i32));
- }
_ => if dest.is_none() {
return err!(Unimplemented(
format!("can't call diverging foreign function: {}", link_name),