[Bug c++/80665] dynamic cast on nullptr leads to segfault

pinskia at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon May 8 12:54:00 GMT 2017


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80665

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
To clarify Richard's statement in the following statement is undefined
Derived* snd_ptr = fst_ptr->as<Derived>();

When fst_ptr is a null pointer.


More information about the Gcc-bugs mailing list