You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
tests: Add "C-unwind" to extern functions that can panic (#1354)
With Rust 1.81 `extern "C"` functions are by-default not allowed to unwind and instead
follow the `panic=abort` strategy. As a consequence, the `#[should_panic]` macro no longer
works on `extern "C"` functions that panic. To mitigate one can change the signature from
`extern "C"` to `extern "C-unwind"` to change the strategy.
This commit does this for any unit test that uses `extern "C"` functions in combination with `#[should_panic]`.
See also rust-lang/rust#116088
0 commit comments