.TH "std::bad_cast" 3cxx "libstdc++" \" -*- nroff -*- .ad l .nh .SH NAME std::bad_cast \- Thrown during incorrect typecasting\&. .SH SYNOPSIS .br .PP .PP \fC#include \fP .PP Inherits \fBstd::exception\fP\&. .PP Inherited by \fBstd::bad_any_cast\fP, and \fBstd::experimental::fundamentals_v1::bad_any_cast\fP\&. .SS "Public Member Functions" .in +1c .ti -1c .RI "\fBvirtual\fP \fBconst\fP char * \fBwhat\fP () \fBconst\fP \fBnoexcept\fP" .br .in -1c .SH "Detailed Description" .PP Thrown during incorrect typecasting\&. If you attempt an invalid \fCdynamic_cast\fP expression, an instance of this class (or something derived from this class) is thrown\&. .br .SH "Member Function Documentation" .PP .SS "\fBvirtual\fP \fBconst\fP 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\&. .br .PP Reimplemented from \fBstd::exception\fP\&. .PP Reimplemented in \fBstd::bad_any_cast\fP, and \fBstd::experimental::fundamentals_v1::bad_any_cast\fP\&. .SH "Author" .PP Generated automatically by Doxygen for libstdc++ from the source code\&.