In the docs page about Mutex there is a sentence: “The mutex can also be statically initialized or created via a new constructor.”. But when I use “static sys_mutex: Mutex = Mutex::new(0 as u32);” I got an error: “statics are not allowed to have destructors”.
How can I use a global Mutex? I need it from 3-4 crates an it must be reachable from there.
P.S.: I use Rust 1.5, which complains about StaticMutex.