https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117785
--- Comment #29 from Jakub Jelinek <jakub at gcc dot gnu.org> --- For std::exception or classes derived from it the standard documents what what() means. For other classes the standard doesn't say anything on those, even if it has const char * return type and is constexpr it could do anything else.