mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-22 14:55:26 +00:00
Rollup merge of #122091 - ChrisDenton:comment, r=RalfJung
Note why we're using a new thread in `test_get_os_named_thread` ``@RalfJung`` expressed some "surprise and confusion" about why we're spawning a new thread in this test. Hopefully this comment will help future readers.
This commit is contained in:
commit
3827584370
@ -80,6 +80,7 @@ fn test_named_thread_truncation() {
|
||||
#[test]
|
||||
fn test_get_os_named_thread() {
|
||||
use crate::sys::thread::Thread;
|
||||
// Spawn a new thread to avoid interfering with other tests running on this thread.
|
||||
let handler = thread::spawn(|| {
|
||||
let name = c"test me please";
|
||||
Thread::set_name(name);
|
||||
|
Loading…
Reference in New Issue
Block a user