Skip to content

Commit bf268fe

Browse files
committed
box mutex to get a movable mutex
the commit avoid an alignement issue in Mutex implementation
1 parent 77d9831 commit bf268fe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/std/src/sys/hermit/mutex.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ pub struct Mutex {
155155
inner: Spinlock<MutexInner>,
156156
}
157157

158-
pub type MovableMutex = Mutex;
158+
pub type MovableMutex = Box<Mutex>;
159159

160160
unsafe impl Send for Mutex {}
161161
unsafe impl Sync for Mutex {}

0 commit comments

Comments
 (0)