> Well, since thread cancellation is implemented using exceptions, and thread cancellation can happen in arbitrary places, we’re always liable to a cancellation happening in a noexcept block, which is undefined behavior, and which in practice will cause your program to crash.<p>I believe the author is mistaken here: throwing an exception that reaches the end of a noexcept block is <i>not</i> undefined behaviour; it will call std::terminate per [except.spec] [1].<p>The linked mailing list post [2] makes no mention of UB, only that this might cause exceptions to be thrown unbeknownst to the programmer in implicitly-noexcept blocks (i.e. destructors) which now might need a noexcept(false) to avoid std::terminate (although that’s still not great because throwing from a destructor will likely lead to resource leaks even if it’s handled).<p>[1] <a href="https://timsong-cpp.github.io/cppwp/n4868/except.spec#5" rel="nofollow">https://timsong-cpp.github.io/cppwp/n4868/except.spec#5</a><p>[2] <a href="https://gcc.gnu.org/legacy-ml/gcc/2017-08/msg00121.html" rel="nofollow">https://gcc.gnu.org/legacy-ml/gcc/2017-08/msg00121.html</a>