This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/58796] throw nullptr not caught by catch(type*)
- From: "redi at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 30 Oct 2013 14:39:31 +0000
- Subject: [Bug c++/58796] throw nullptr not caught by catch(type*)
- Auto-submitted: auto-generated
- References: <bug-58796-4 at http dot gcc dot gnu dot org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58796
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2013-10-30
Ever confirmed|0 |1
--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
I agree this looks like a bug. Reduced:
struct A {};
typedef int A::*PointerToMember;
int main() {
try {
throw nullptr;
} catch (PointerToMember) { // This *should* catch throw nullptr...
}
try {
throw nullptr;
} catch(void *) { // This *should* catch throw nullptr...
}
}