Are std::signal and std::raise thread-safe?
问题 The C and C++ standards support the concept of signal. However, the C11 standard says that the function signal() cannot be called in multi-threaded environments, or the behavior is undefined. But I think the signal mechanism is by nature for multi-threaded environments. A quote from the C11 standard 7.14.1.1.7 "Use of this function in a multi-threaded program results in undefined behavior. The implementation shall behave as if no library function calls the signal function." Any explanations