3 ms·
Re: non-thread-safe items in lazy_static, you can also wrap them in a mutex within just the lazy_static so the struct only uses synchronization when it actually
by dikaiosune 8y ago
Re: non-thread-safe items in lazy_static, you can also wrap them in a mutex within just the lazy_static so the struct only uses synchronization when it actually needs to be thread-safe.
- deleted 8y ago[deleted]
- dbaupp 8y agoThat removes the Sync requirement, but still requires Send, so doesn't completely resolve the requirement for thread-safety (e.g. Rc can't be stored).