【发布时间】:2013-04-17 03:10:45
【问题描述】:
我正在尝试控制代码中引发的异常,但是此示例在 C++ Builder 5 下无法正常工作。
void __fastcall TForm1::Button1Click(TObject *Sender)
{
try
{
throw Exception("NoNumber");
}
catch(Exception& E)
{
// but we never get the LALAL message
ShowMessage("LALAL");
}
}
为什么在引发异常时永远不会到达 catch 块?
【问题讨论】:
标签: exception-handling c++builder vcl c++builder-5