Comment on In the C++ bag of tricks: scoped locksComments−jacobparker12yException issues aside, an odd definition of "scoped". A very non-C++ solution. Use RAII and lock_guard (if possible) as vinkelhake demonstrates. Consider, LOCKED(lk_var) { return 42; // whoops }
Comments
Exception issues aside, an odd definition of "scoped". A very non-C++ solution. Use RAII and lock_guard (if possible) as vinkelhake demonstrates. Consider,