Return type normalization, and change return errors from imported functions

This commit is contained in:
Lachlan Sneff
2019-04-22 11:42:52 -07:00
parent 85d9ca9ad2
commit 74b6ba4eaf
8 changed files with 115 additions and 109 deletions

View File

@ -76,7 +76,7 @@ pub fn call_protected<T>(handler_data: &HandlerData, f: impl FnOnce() -> T) -> R
*jmp_buf = prev_jmp_buf;
if let Some(data) = super::TRAP_EARLY_DATA.with(|cell| cell.replace(None)) {
Err(RuntimeError::Panic { data })
Err(RuntimeError::Error { data })
} else {
let (faulting_addr, inst_ptr) = CAUGHT_ADDRESSES.with(|cell| cell.get());