[PATCH] c++/58796 Make nullptr match exception handlers of pointer type
Jonathan Wakely
jwakely@redhat.com
Fri Jul 15 11:47:00 GMT 2016
This allows exception handlers of pointer and pointer to data members
to match exceptions of type std::nullptr_t.
Pointers to member functions don't work yet, because a nullptr_t
exception object is only a single word, and we need two words for a
pointer to member function, and we don't have anywhere to put those
two words in the exception object. I'm going to raise this with the
C++ ABI group to coordinate with other implementations.
Tested x86_64-linux, I plan to commit this to trunk soon.
libstdc++-v3:
PR c++/58796
* libsupc++/pbase_type_info.cc (__pbase_type_info::__do_catch): Make
nullptr match handlers of pointer type.
gcc/testsuite:
PR c++/58796
* g++.dg/cpp0x/nullptr21.C: Remove void* handlers.
* g++.dg/cpp0x/nullptr35.C: New test.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.txt
Type: text/x-patch
Size: 3521 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/libstdc++/attachments/20160715/b46ffe4f/attachment.bin>
More information about the Libstdc++
mailing list