Skip to content

Commit dafbec7

Browse files
committed
coverage: remove panic_unwind hack
1 parent e66231a commit dafbec7

File tree

3 files changed

+0
-17
lines changed

3 files changed

+0
-17
lines changed

src/err/mod.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -557,12 +557,6 @@ mod tests {
557557
#[test]
558558
#[should_panic(expected = "new panic")]
559559
fn fetching_panic_exception_resumes_unwind() {
560-
// TODO replace with #[cfg(panic = "unwind")] once stable
561-
if !crate::cfg_panic_unwind() {
562-
// panic to meet the expected abort in panic=abort :-/
563-
panic!("new panic");
564-
}
565-
566560
use crate::panic::PanicException;
567561

568562
let gil = Python::acquire_gil();

src/lib.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -425,9 +425,3 @@ pub mod doc_test {
425425
doctest!("guide/src/trait_bounds.md", guide_trait_bounds_md);
426426
doctest!("guide/src/types.md", guide_types_md);
427427
}
428-
429-
// interim helper until #[cfg(panic = ...)] is stable
430-
#[cfg(test)]
431-
fn cfg_panic_unwind() -> bool {
432-
option_env!("RUSTFLAGS").map_or(true, |var| !var.contains("-Cpanic=abort"))
433-
}

src/python.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -695,11 +695,6 @@ mod test {
695695

696696
#[test]
697697
fn test_allow_threads_panics_safely() {
698-
// TODO replace with #[cfg(panic = "unwind")] once stable
699-
if !crate::cfg_panic_unwind() {
700-
return;
701-
}
702-
703698
let gil = Python::acquire_gil();
704699
let py = gil.python();
705700

0 commit comments

Comments
 (0)