Saturday, 28 September 2013

Google C++ coding style, no exceptions rule. What about multithreading?

Google C++ coding style, no exceptions rule. What about multithreading?

Google C++ coding style recommends against C++ exceptions, and we don't
use them too. For most of the STL library containers one can just ignore
the exceptions, because normally they indicate critical errors and are
difficult to handle anyway, so crashing is acceptable.
However there is a problem with multi-threading (std::thread), for example
entering a non-recursive mutex twice throws an exception. This situation
is not critical and could be handled by waiting.
My question is: anyone knows what is Google using as a threading library?
Is there any C++ cross-platform threading library that doesn't use
exceptions?
Thank you

No comments:

Post a Comment