| C++ noexcept exists because the way C++ evolved, it is no argument against exceptions. Exceptions came to be during the 1990's, as the C++ARM to C++98 standardisation process was taking place. Naturally during the early days C++ compilers lacked exceptions, as CFront was introduced without them. Then we had the C folks that were migrating to C++. When C++ compilers finally supported exception, compilers vendors introduced the non standard switch to disable them, so that existing code could still compile with the expected behaviour. The standard itself does not acknowledge this as allowed. This feature was naturally misused by the anti-exception folks, same applies to how RTTI came to be. So noexcept is a way to be able to write code to appease both camps, while surfacing what variant was chosen by the programmer. From my point of view allowing disabling exceptions in first place was a mistake, those folks should have moved back to C, or fixed their code. |