.TH "std::bad_cast" 3cxx "Tue Jul 2 2019" "libstdc++" \" -*- nroff -*- .ad l .nh .SH NAME std::bad_cast \- Thrown during incorrect typecasting\&. .PP If you attempt an invalid \fCdynamic_cast\fP expression, an instance of this class (or something derived from this class) is thrown\&. .SH SYNOPSIS .br .PP .PP Inherits \fBstd::exception\fP\&. .PP Inherited by \fBstd::experimental::fundamentals_v1::bad_any_cast\fP\&. .SS "Public Member Functions" .in +1c .ti -1c .RI "virtual const char * \fBwhat\fP () const noexcept" .br .in -1c .SH "Detailed Description" .PP Thrown during incorrect typecasting\&. .PP If you attempt an invalid \fCdynamic_cast\fP expression, an instance of this class (or something derived from this class) is thrown\&. .PP Definition at line 187 of file typeinfo\&. .SH "Member Function Documentation" .PP .SS "virtual const char* std::bad_cast::what () const\fC [virtual]\fP, \fC [noexcept]\fP" Returns a C-style character string describing the general cause of the current error\&. .PP Reimplemented from \fBstd::exception\fP\&. .PP Reimplemented in \fBstd::experimental::fundamentals_v1::bad_any_cast\fP\&. .SH "Author" .PP Generated automatically by Doxygen for libstdc++ from the source code\&.