rust-lang / rust

Empowering everyone to build reliable and efficient software.
https://www.rust-lang.org
Other
97.29k stars 12.58k forks source link

regression: panic in a function that should not panic #128900

Open BoxyUwU opened 1 month ago

BoxyUwU commented 1 month ago
[INFO] [stderr] thread 'tests::test_default' panicked at library/core/src/panicking.rs:221:5:
[INFO] [stderr] panic in a function that cannot unwind
[INFO] [stderr] stack backtrace:
compiler-errors commented 1 month ago

This is due to changes falling out of the stabilization of the C-unwind ABI #116088 cc @nbdd0121 @Amanieu @RalfJung

nbdd0121 commented 1 month ago

All of them seem to be not using -unwind ABIs when unwinding across FFI and the breakage is intended.

trying to unwind past extern "C" in near_sdk 4.0.0 (not latest version)

trying to unwind past extern "system" in the crate itself: https://github.com/outfoxxed/mock-gl/blob/5fd7c575162dd5edd43470482529c320a440eaeb/src/function_mapping.rs#L34.

trying to unwind past extern "C" function in the crate itself: https://github.com/qir-alliance/qir-runner/blob/7b41f9313609f8309317ce91afccf0a2c7fe5a6f/stdlib/src/lib.rs#L83.

trying to unwind past extern "C" function in the crate itself: https://github.com/wasm-forge/ic-wasi-polyfill/blob/0e0858cb2c3dd89b586527f9271cdd338022d814/src/lib.rs#L1048