Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Yikes, of course it should be noexcept instead of nothrow in my previous post!

However, I don't find any referenc to noexcept having gotten defined behaviour. Do you have any pointers?



In the current version of the standard on the GitHub repo [0], Section 14.5 Paragraph 5 says:

> Whenever an exception is thrown and the search for a handler (14.4) encounters the outermost block of a function with a non-throwing exception specification, the function std::terminate is called (14.6.1).

I don't know when precisely noexcept was changed to call std::terminate, but I did find N3103 (included in the 2010-08 post-Rapperswil mailing [1]), which argued that the standard should require calling std::terminate to avoid security issues.

[0]: https://github.com/cplusplus/draft [1]: http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2010/n310...




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: