bad_exception 类
该类描述可从意外处理程序引发的异常。
语法
class bad_exception : public exception {};
bad_exception();
bad_exception(const bad_exception&);
bad_exception& operator=(const bad_exception&);
const char* what() const override;
备注
如果 bad_exception
包含在函数的引发列表中,则 unexpected 将引发 bad_exception
,而不是终止或调用使用 set_unexpected 指定的其他函数。
what
返回的值是实现定义的 C 字符串。 无成员函数引发任何异常。
有关通过 bad_exception
类继承的成员列表,请参阅 exception 类。
示例
有关引发 bad_exception
的 unexpected 的使用示例,请参阅 set_unexpected。
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈