Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit294d87f

Browse files
committed
Remove non-focused memory leak instd doctest for Miri.
1 parent5515bba commit294d87f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

‎std/src/sync/condvar.rs‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ impl WaitTimeoutResult {
3535
/// let pair = Arc::new((Mutex::new(false), Condvar::new()));
3636
/// let pair2 = Arc::clone(&pair);
3737
///
38+
/// # let handle =
3839
/// thread::spawn(move || {
3940
/// let (lock, cvar) = &*pair2;
4041
///
@@ -58,6 +59,8 @@ impl WaitTimeoutResult {
5859
/// break
5960
/// }
6061
/// }
62+
/// # // Prevent leaks for Miri.
63+
/// # let _ = handle.join();
6164
/// ```
6265
#[must_use]
6366
#[stable(feature ="wait_timeout", since ="1.5.0")]

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp