P0003R5 - removal of dynamic exception specification from C++17
commitfbf8561eb18554d401fb355a2f34803c51cc32b2
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 8 Dec 2016 08:26:06 +0000 (8 08:26 +0000)
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 8 Dec 2016 08:26:06 +0000 (8 08:26 +0000)
tree5ecd32fc451a6802fb2f17da35cdfddb84b114d3
parentbeea0800baadbe98febe5a4e54112d76ea10a9d3
P0003R5 - removal of dynamic exception specification from C++17
* parser.c (cp_parser_exception_specification_opt): For C++17
error out on throw ( type-id-list ), for C++11 and C++14 issue
-Wdeprecated warning on it.  Formatting fix.  Treat throw()
in C++17 as noexcept(true).

* g++.dg/compat/eh/ctor1.h: Adjust for deprecation of
throw (type-id-list) in C++11 and C++14 and removal in C++17.
* g++.dg/compat/eh/ctor1_y.C: Likewise.
* g++.dg/compat/eh/new1_x.C: Likewise.
* g++.dg/compat/eh/new1_y.C: Likewise.
* g++.dg/compat/eh/spec3_x.C: Likewise.
* g++.dg/compat/eh/spec3_y.C: Likewise.
* g++.dg/compat/eh/template1.h: Likewise.
* g++.dg/compat/eh/template1_y.C: Likewise.
* g++.dg/compat/eh/unexpected1_x.C: Likewise.
* g++.dg/compat/eh/unexpected1_y.C: Likewise.
* g++.dg/cpp0x/auto9.C: Likewise.
* g++.dg/cpp0x/defaulted23.C: Likewise.
* g++.dg/cpp0x/error5.C: Likewise.
* g++.dg/cpp0x/lambda/lambda-eh2.C: Likewise.
* g++.dg/cpp0x/noexcept02.C: Likewise.
* g++.dg/cpp0x/noexcept07.C: Likewise.
* g++.dg/cpp0x/noexcept08.C: Likewise.
* g++.dg/cpp0x/noexcept19.C: Likewise.
* g++.dg/cpp0x/variadic73.C: Likewise.
* g++.dg/cpp0x/variadic-throw.C: Likewise.
* g++.dg/cpp1z/noexcept-type1.C: Likewise.
* g++.dg/eh/async-unwind2.C: Likewise.
* g++.dg/eh/cond4.C: Likewise.
* g++.dg/eh/delete1.C: Likewise.
* g++.dg/eh/ehopt1.C: Likewise.
* g++.dg/eh/forced3.C: Likewise.
* g++.dg/eh/forced4.C: Likewise.
* g++.dg/eh/init-temp2.C: Likewise.
* g++.dg/eh/pr38662.C: Likewise.
* g++.dg/eh/pr41819.C: Likewise.
* g++.dg/eh/shadow1.C: Likewise.
* g++.dg/eh/spec2.C: Likewise.
* g++.dg/eh/spec3.C: Likewise.
* g++.dg/eh/spec5.C: Likewise.
* g++.dg/eh/spec6.C: Likewise.
* g++.dg/eh/spec7.C: Likewise.
* g++.dg/eh/spec8.C: Likewise.
* g++.dg/eh/spec9.C: Likewise.
* g++.dg/eh/template1.C: Likewise.
* g++.dg/eh/unexpected1.C: Likewise.
* g++.dg/ext/has_nothrow_assign.C: Likewise.
* g++.dg/ext/has_nothrow_constructor.C: Likewise.
* g++.dg/ext/has_nothrow_copy-1.C: Likewise.
* g++.dg/ext/has_nothrow_copy-2.C: Likewise.
* g++.dg/ext/has_nothrow_copy-4.C: Likewise.
* g++.dg/ext/has_nothrow_copy-5.C: Likewise.
* g++.dg/ext/has_nothrow_copy-6.C: Likewise.
* g++.dg/ext/has_nothrow_copy-7.C: Likewise.
* g++.dg/gcov/gcov-7.C: Likewise.
* g++.dg/init/new13.C: Likewise.
* g++.dg/init/new25.C: Likewise.
* g++.dg/lookup/exception1.C: Likewise.
* g++.dg/opt/noreturn-1.C: Likewise.
* g++.dg/other/error3.C: Likewise.
* g++.dg/rtti/crash3.C: Likewise.
* g++.dg/template/eh2.C: Likewise.
* g++.dg/template/error36.C: Likewise.
* g++.dg/tm/pr46567.C: Likewise.
* g++.dg/tm/pr47340.C: Likewise.
* g++.dg/torture/pr46364.C: Likewise.
* g++.dg/torture/pr49394.C: Likewise.
* g++.dg/torture/pr52918-1.C: Likewise.
* g++.dg/torture/pr57190.C: Likewise.
* g++.dg/torture/stackalign/eh-alloca-1.C: Likewise.
* g++.dg/torture/stackalign/eh-fastcall-1.C: Likewise.
* g++.dg/torture/stackalign/eh-global-1.C: Likewise.
* g++.dg/torture/stackalign/eh-inline-1.C: Likewise.
* g++.dg/torture/stackalign/eh-inline-2.C: Likewise.
* g++.dg/torture/stackalign/eh-thiscall-1.C: Likewise.
* g++.dg/torture/stackalign/eh-vararg-1.C: Likewise.
* g++.dg/torture/stackalign/eh-vararg-2.C: Likewise.
* g++.dg/tree-ssa/pr45605.C: Likewise.
* g++.dg/warn/Wreturn-type-3.C: Likewise.
* g++.old-deja/g++.eh/badalloc1.C: Likewise.
* g++.old-deja/g++.eh/cleanup2.C: Likewise.
* g++.old-deja/g++.eh/spec1.C: Likewise.
* g++.old-deja/g++.eh/spec2.C: Likewise.
* g++.old-deja/g++.eh/spec3.C: Likewise.
* g++.old-deja/g++.eh/spec4.C: Likewise.
* g++.old-deja/g++.eh/spec6.C: Likewise.
* g++.old-deja/g++.eh/throw1.C: Likewise.
* g++.old-deja/g++.eh/throw2.C: Likewise.
* g++.old-deja/g++.eh/tmpl1.C: Likewise.
* g++.old-deja/g++.eh/tmpl3.C: Likewise.
* g++.old-deja/g++.mike/eh15.C: Likewise.
* g++.old-deja/g++.mike/eh25.C: Likewise.
* g++.old-deja/g++.mike/eh33.C: Likewise.
* g++.old-deja/g++.mike/eh34.C: Likewise.
* g++.old-deja/g++.mike/eh50.C: Likewise.
* g++.old-deja/g++.mike/eh51.C: Likewise.
* g++.old-deja/g++.mike/eh55.C: Likewise.
* g++.old-deja/g++.mike/p10416.C: Likewise.
* g++.old-deja/g++.other/crash28.C: Likewise.
* g++.old-deja/g++.other/crash30.C: Likewise.
* g++.old-deja/g++.other/new7.C: Likewise.
* g++.old-deja/g++.pt/ehspec1.C: Likewise.
* g++.old-deja/g++.robertl/eb123.C: Likewise.

* testsuite/util/testsuite_new_operators.h: Include testsuite_hooks.h.
(operator new): Use THROW macro.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243429 138bc75d-0d04-0410-961f-82ee72b054a4
102 files changed:
gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/compat/eh/ctor1.h
gcc/testsuite/g++.dg/compat/eh/ctor1_y.C
gcc/testsuite/g++.dg/compat/eh/new1_x.C
gcc/testsuite/g++.dg/compat/eh/new1_y.C
gcc/testsuite/g++.dg/compat/eh/spec3_x.C
gcc/testsuite/g++.dg/compat/eh/spec3_y.C
gcc/testsuite/g++.dg/compat/eh/template1.h
gcc/testsuite/g++.dg/compat/eh/template1_y.C
gcc/testsuite/g++.dg/compat/eh/unexpected1_x.C
gcc/testsuite/g++.dg/compat/eh/unexpected1_y.C
gcc/testsuite/g++.dg/cpp0x/auto9.C
gcc/testsuite/g++.dg/cpp0x/defaulted23.C
gcc/testsuite/g++.dg/cpp0x/error5.C
gcc/testsuite/g++.dg/cpp0x/lambda/lambda-eh2.C
gcc/testsuite/g++.dg/cpp0x/noexcept02.C
gcc/testsuite/g++.dg/cpp0x/noexcept07.C
gcc/testsuite/g++.dg/cpp0x/noexcept08.C
gcc/testsuite/g++.dg/cpp0x/noexcept19.C
gcc/testsuite/g++.dg/cpp0x/variadic-throw.C
gcc/testsuite/g++.dg/cpp0x/variadic73.C
gcc/testsuite/g++.dg/cpp1z/noexcept-type1.C
gcc/testsuite/g++.dg/eh/async-unwind2.C
gcc/testsuite/g++.dg/eh/cond4.C
gcc/testsuite/g++.dg/eh/delete1.C
gcc/testsuite/g++.dg/eh/ehopt1.C
gcc/testsuite/g++.dg/eh/forced3.C
gcc/testsuite/g++.dg/eh/forced4.C
gcc/testsuite/g++.dg/eh/init-temp2.C
gcc/testsuite/g++.dg/eh/pr38662.C
gcc/testsuite/g++.dg/eh/pr41819.C
gcc/testsuite/g++.dg/eh/shadow1.C
gcc/testsuite/g++.dg/eh/spec2.C
gcc/testsuite/g++.dg/eh/spec3.C
gcc/testsuite/g++.dg/eh/spec5.C
gcc/testsuite/g++.dg/eh/spec6.C
gcc/testsuite/g++.dg/eh/spec7.C
gcc/testsuite/g++.dg/eh/spec8.C
gcc/testsuite/g++.dg/eh/spec9.C
gcc/testsuite/g++.dg/eh/template1.C
gcc/testsuite/g++.dg/eh/unexpected1.C
gcc/testsuite/g++.dg/ext/has_nothrow_assign.C
gcc/testsuite/g++.dg/ext/has_nothrow_constructor.C
gcc/testsuite/g++.dg/ext/has_nothrow_copy-1.C
gcc/testsuite/g++.dg/ext/has_nothrow_copy-2.C
gcc/testsuite/g++.dg/ext/has_nothrow_copy-4.C
gcc/testsuite/g++.dg/ext/has_nothrow_copy-5.C
gcc/testsuite/g++.dg/ext/has_nothrow_copy-6.C
gcc/testsuite/g++.dg/ext/has_nothrow_copy-7.C
gcc/testsuite/g++.dg/gcov/gcov-7.C
gcc/testsuite/g++.dg/init/new13.C
gcc/testsuite/g++.dg/init/new25.C
gcc/testsuite/g++.dg/lookup/exception1.C
gcc/testsuite/g++.dg/opt/noreturn-1.C
gcc/testsuite/g++.dg/other/error3.C
gcc/testsuite/g++.dg/rtti/crash3.C
gcc/testsuite/g++.dg/template/eh2.C
gcc/testsuite/g++.dg/template/error36.C
gcc/testsuite/g++.dg/tm/pr46567.C
gcc/testsuite/g++.dg/tm/pr47340.C
gcc/testsuite/g++.dg/torture/pr46364.C
gcc/testsuite/g++.dg/torture/pr49394.C
gcc/testsuite/g++.dg/torture/pr52918-1.C
gcc/testsuite/g++.dg/torture/pr57190.C
gcc/testsuite/g++.dg/torture/stackalign/eh-alloca-1.C
gcc/testsuite/g++.dg/torture/stackalign/eh-fastcall-1.C
gcc/testsuite/g++.dg/torture/stackalign/eh-global-1.C
gcc/testsuite/g++.dg/torture/stackalign/eh-inline-1.C
gcc/testsuite/g++.dg/torture/stackalign/eh-inline-2.C
gcc/testsuite/g++.dg/torture/stackalign/eh-thiscall-1.C
gcc/testsuite/g++.dg/torture/stackalign/eh-vararg-1.C
gcc/testsuite/g++.dg/torture/stackalign/eh-vararg-2.C
gcc/testsuite/g++.dg/tree-ssa/pr45605.C
gcc/testsuite/g++.dg/warn/Wreturn-type-3.C
gcc/testsuite/g++.old-deja/g++.eh/badalloc1.C
gcc/testsuite/g++.old-deja/g++.eh/cleanup2.C
gcc/testsuite/g++.old-deja/g++.eh/spec1.C
gcc/testsuite/g++.old-deja/g++.eh/spec2.C
gcc/testsuite/g++.old-deja/g++.eh/spec3.C
gcc/testsuite/g++.old-deja/g++.eh/spec4.C
gcc/testsuite/g++.old-deja/g++.eh/spec6.C
gcc/testsuite/g++.old-deja/g++.eh/throw1.C
gcc/testsuite/g++.old-deja/g++.eh/throw2.C
gcc/testsuite/g++.old-deja/g++.eh/tmpl1.C
gcc/testsuite/g++.old-deja/g++.eh/tmpl3.C
gcc/testsuite/g++.old-deja/g++.mike/eh15.C
gcc/testsuite/g++.old-deja/g++.mike/eh25.C
gcc/testsuite/g++.old-deja/g++.mike/eh33.C
gcc/testsuite/g++.old-deja/g++.mike/eh34.C
gcc/testsuite/g++.old-deja/g++.mike/eh50.C
gcc/testsuite/g++.old-deja/g++.mike/eh51.C
gcc/testsuite/g++.old-deja/g++.mike/eh55.C
gcc/testsuite/g++.old-deja/g++.mike/p10416.C
gcc/testsuite/g++.old-deja/g++.other/crash28.C
gcc/testsuite/g++.old-deja/g++.other/crash30.C
gcc/testsuite/g++.old-deja/g++.other/new7.C
gcc/testsuite/g++.old-deja/g++.pt/ehspec1.C
gcc/testsuite/g++.old-deja/g++.robertl/eb123.C
libstdc++-v3/ChangeLog
libstdc++-v3/testsuite/util/testsuite_new_operators.h