excrt_11.c
来自「开放源码的编译器open watcom 1.6.0版的源代码」· C语言 代码 · 共 25 行
C
25 行
// 94/06/09 -- jww -- fixed R/T system
#include "fail.h"
#include <except.h>
void my_terminate()
{
throw __FILE__ ": should never see this printed!" ;
}
int main()
{
set_terminate(my_terminate) ;
try
{
throw 1 ; // no catch block
}
catch(const char* message)
{
printf( "%s\n", message );
_fail;
}
_PASS;
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?