@@ -1405,7 +1405,6 @@ fn test_box_slice_clone() {
1405
1405
#[ test]
1406
1406
#[ allow( unused_must_use) ] // here, we care about the side effects of `.clone()`
1407
1407
#[ cfg_attr( target_os = "emscripten" , ignore) ]
1408
- #[ cfg( not( miri) ) ] // Miri does not support catching panics
1409
1408
fn test_box_slice_clone_panics ( ) {
1410
1409
use std:: sync:: Arc ;
1411
1410
use std:: sync:: atomic:: { AtomicUsize , Ordering } ;
@@ -1595,7 +1594,6 @@ thread_local!(static SILENCE_PANIC: Cell<bool> = Cell::new(false));
1595
1594
1596
1595
#[ test]
1597
1596
#[ cfg_attr( target_os = "emscripten" , ignore) ] // no threads
1598
- #[ cfg( not( miri) ) ] // Miri does not support catching panics
1599
1597
fn panic_safe ( ) {
1600
1598
let prev = panic:: take_hook ( ) ;
1601
1599
panic:: set_hook ( Box :: new ( move |info| {
@@ -1606,7 +1604,12 @@ fn panic_safe() {
1606
1604
1607
1605
let mut rng = thread_rng ( ) ;
1608
1606
1609
- for len in ( 1 ..20 ) . chain ( 70 ..MAX_LEN ) {
1607
+ #[ cfg( not( miri) ) ] // Miri is too slow
1608
+ let large_range = 70 ..MAX_LEN ;
1609
+ #[ cfg( miri) ]
1610
+ let large_range = 0 ..0 ; // empty range
1611
+
1612
+ for len in ( 1 ..20 ) . chain ( large_range) {
1610
1613
for & modulus in & [ 5 , 20 , 50 ] {
1611
1614
for & has_runs in & [ false , true ] {
1612
1615
let mut input = ( 0 ..len)
0 commit comments