You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: thread_locals.rs
    path of file: ./repos/flume/tests
    
    the code of the file until where you have to start completion: // //! Tests that make sure accessing thread-locals while exiting the thread doesn't cause panics.

// exte
    
// fn use_while_exiting() {
//     struct Foo;

//     impl Drop for Foo {
//         fn drop(&mut self) {
//             // A blocking operation after the thread-locals have been dropped. This will attempt to
//             // use the thread-locals and must not panic.
//             let (_s, r) = unbounded::<()>();
//             select! {
//                 recv(r) -> _ => {}
//                 default(ms(100)) => {}
//             }
//         }
//     }

//     thread_local! {
//         static FOO: Foo = Foo;
//     }

//     let (s, r) = unbounded::<()>();

//     scope(|scope| {
//         scope.spawn(|_| {
//             // First initialize `FOO`, then the thread-locals related to crossbeam-channel.
//             FOO.with(|_| ());
//             r.recv().unwrap();
//             // At thread exit, thread-locals related to crossbeam-channel get dropped first and
//             // `FOO` is dropped last.
//         });

//         scope.spawn(|_| {
//             thread::sleep(ms(100));
//             s.send(()).unwrap();
//         });
//     })
//     .unwrap();
// }