Skip to content

Commit

Permalink
std: Ignore tests where threads outlive main
Browse files Browse the repository at this point in the history
Long ago we discovered that threads which outlive main and then exit while the
rest of the program is exiting causes Windows to hang (#20704). That's what was
happening in this test so let's just not run this test any more.
  • Loading branch information
alexcrichton committed Jul 22, 2016
1 parent eb196dc commit 8487666
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/liballoc/arc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,10 @@
//!
//! Sharing some immutable data between threads:
//!
// Note that we **do not** run these tests here. The windows builders get super
// unhappy of a thread outlives the main thread and then exits at the same time
// (something deadlocks) so we just avoid this entirely by not running these
// tests.
//! ```no_run
//! use std::sync::Arc;
//! use std::thread;
Expand Down Expand Up @@ -97,7 +101,8 @@ const MAX_REFCOUNT: usize = (isize::MAX) as usize;
/// by putting it inside `Mutex` and then share `Mutex` immutably
/// with `Arc<T>` as shown below.
///
/// ```
// See comment at the top of this file for why the test is no_run
/// ```no_run
/// use std::sync::{Arc, Mutex};
/// use std::thread;
///
Expand Down

0 comments on commit 8487666

Please sign in to comment.