Rollup merge of #152472 - lizan:wasm, r=Mark-Simulacrum

unwind/wasm: fix compile error by wrapping wasm_throw in unsafe block

This fix rust-std compile error on wasm32-unknown-unknown with panic=unwind because of `#![deny(unsafe_op_in_unsafe_fn)]`
This commit is contained in:
Jacob Pratt
2026-02-14 23:17:41 -05:00
committed by GitHub
+1 -1
View File
@@ -73,7 +73,7 @@ pub unsafe fn _Unwind_RaiseException(exception: *mut _Unwind_Exception) -> _Unwi
// corresponds with llvm::WebAssembly::Tag::CPP_EXCEPTION
// in llvm-project/llvm/include/llvm/CodeGen/WasmEHFuncInfo.h
const CPP_EXCEPTION_TAG: i32 = 0;
wasm_throw(CPP_EXCEPTION_TAG, exception.cast())
unsafe { wasm_throw(CPP_EXCEPTION_TAG, exception.cast()) }
}
_ => {
let _ = exception;