From 4f1353e54f9cdca82487b5e69f94e54047d8ea2f Mon Sep 17 00:00:00 2001 From: Mara Bos Date: Thu, 1 Oct 2020 01:09:48 +0200 Subject: [PATCH] No longer put wasm mutexes in a box. These mutexes are just an AtomicUsize, so can be moved without problems. --- library/std/src/sys/wasm/mutex_atomics.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/std/src/sys/wasm/mutex_atomics.rs b/library/std/src/sys/wasm/mutex_atomics.rs index 5d45efe19c2..2970fcf806c 100644 --- a/library/std/src/sys/wasm/mutex_atomics.rs +++ b/library/std/src/sys/wasm/mutex_atomics.rs @@ -8,7 +8,7 @@ pub struct Mutex { locked: AtomicUsize, } -pub type MovableMutex = Box; +pub type MovableMutex = Mutex; // Mutexes have a pretty simple implementation where they contain an `i32` // internally that is 0 when unlocked and 1 when the mutex is locked.