// S : tags c++ $TAGS // S : expect --result valid // S : cc -o test.bc $CC_OPT $file // S : verify $V_OPT test.bc #include #include int main() { int *x = nullptr; int y = 0; try { x = new int; y = 1; } catch( std::exception ) { y = 2; } assert( ( x && y == 1 ) || ( !x && y == 2 ) ); delete x; return 0; }