Rollup merge of #125927 - ferrocene:lw-alloc-unwind-test, r=pietroalbini

Ignore `vec_deque_alloc_error::test_shrink_to_unwind` test on non-unwind targets

https://github.com/rust-lang/rust/pull/123803 added this test which requires unwinding to succeed. This conditionally ignores the test on non-unwind targets (as is the case with other tests using `catch_unwind`).
This commit is contained in:
Guillaume Gomez 2024-06-04 21:41:35 +02:00 committed by GitHub
commit d9e149d9d8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -8,6 +8,7 @@ use std::{
};
#[test]
#[cfg_attr(not(panic = "unwind"), ignore = "test requires unwinding support")]
fn test_shrink_to_unwind() {
// This tests that `shrink_to` leaves the deque in a consistent state when
// the call to `RawVec::shrink_to_fit` unwinds. The code is adapted from #123369