Correct me if I'm wrong, but critical-section's Mutex allows Mutex<T> even if T: !Sync. However, OnceCell's implementation based on critical-section requires T: Send + Sync, and syncing is precisely the work of the Mutex used. Should this bound be removed?
Correct me if I'm wrong, but
critical-section
'sMutex
allowsMutex<T>
even ifT: !Sync
. However,OnceCell
's implementation based oncritical-section
requiresT: Send + Sync
, and syncing is precisely the work of theMutex
used. Should this bound be removed?