或者 try { // code that could throw an exception } [ catch (exception-declaration) { // code that executes when exception-declaration is thrown // in the try block } [catch (exception-declaration) { // code that handles another exception type } ] . . . ] // The following syntax shows a throw expression: throw [expression]
{
// guarded code
}
__except ( expression )
{
// exception handler code
}
try {
// code that could throw an exception
}
[ catch (exception-declaration) {
// code that executes when exception-declaration is thrown
// in the try block
}
[catch (exception-declaration) {
// code that handles another exception type
} ] . . . ]
// The following syntax shows a throw expression:
throw [expression]
{
}catch( ... )
{
}