https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77864
Bug ID: 77864 Summary: [5/6/7 Regression] Wrong exception specification on maps and sets Product: gcc Version: 5.4.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: redi at gcc dot gnu.org Target Milestone: --- #include <set> struct cmp { cmp() { throw 1; } bool operator()(int l, int r) const { return l < r; } }; int main() { try { std::set<int, cmp> c; } catch (...) { } } This runs OK as C++98 or with GCC 4.9, but terminates using C++11 and up since GCC 5 when I added noexcept to the default ctors for associative containers.