PR c++/89612 - ICE with member friend template with noexcept.
authorMarek Polacek <polacek@redhat.com>
Thu, 28 Mar 2019 20:24:48 +0000 (20:24 +0000)
committerMarek Polacek <mpolacek@gcc.gnu.org>
Thu, 28 Mar 2019 20:24:48 +0000 (20:24 +0000)
commitc526171d734653ebde26fc8a29191247add7bf3e
tree805536d2cc95687eeccf43591de8bbe41bb4972e
parentddfd99ac13bf63ba7cb9ca30cd9b16d41f5c664a
PR c++/89612 - ICE with member friend template with noexcept.

* pt.c (maybe_instantiate_noexcept): For function templates, use their
template result (function decl).  Don't set up local specializations.
Temporarily turn on processing_template_decl.  Update the template type
too.

* g++.dg/cpp0x/noexcept38.C: New test.
* g++.dg/cpp0x/noexcept39.C: New test.
* g++.dg/cpp1z/noexcept-type21.C: New test.

From-SVN: r270005
gcc/cp/ChangeLog
gcc/cp/pt.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/cpp0x/noexcept38.C [new file with mode: 0644]
gcc/testsuite/g++.dg/cpp0x/noexcept39.C [new file with mode: 0644]
gcc/testsuite/g++.dg/cpp1z/noexcept-type21.C [new file with mode: 0644]