This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/71100] New: [6.1 regression] Internal compiler error while calling a pointer to member function that throws
- From: "ogoffart at kde dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 13 May 2016 09:14:11 +0000
- Subject: [Bug c++/71100] New: [6.1 regression] Internal compiler error while calling a pointer to member function that throws
- Auto-submitted: auto-generated
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71100
Bug ID: 71100
Summary: [6.1 regression] Internal compiler error while calling
a pointer to member function that throws
Product: gcc
Version: 6.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: ogoffart at kde dot org
Target Milestone: ---
This code crashes GCC 6.1 when optimisations are enabled:
-----------------------------------------------------------
struct Destr
{ ~Destr(); };
struct XX
{
Destr func() {
throw "throw";
return {};
}
};
inline void call(Destr (XX::*f)(), XX *o)
{
(o->*f)();
}
void f(XX *o) {
call(&XX::func, o);
}
-----------------------------------------------------------
Live demo:
http://melpon.org/wandbox/permlink/GyM44dSdEnvqqmZN