eckit::Mutex class

Reentrant Mutex In addition to std::reentrant_mutex this checks valida construction before usage and add an optional tag, both of which can be useful when debugging, especially when dealing with construction before main() execution (eg self-registration classes)

Constructors, destructors, conversion operators

Mutex(char tag = ' ')
Mutex(const Mutex&) deleted
Mutex(Mutex&&) deleted
~Mutex()

Public functions

auto operator=(const Mutex&) -> Mutex& deleted
auto operator=(Mutex&&) -> Mutex& deleted
void lock()
void unlock()
auto tryLock() -> bool
auto tag() const -> char