1*746bf85eSotto #include <iostream> 2*746bf85eSotto 3*746bf85eSotto 4*746bf85eSotto class ex { 5*746bf85eSotto }; 6*746bf85eSotto f(void)7*746bf85eSottovoid f(void) { 8*746bf85eSotto throw ex(); 9*746bf85eSotto } 10*746bf85eSotto main()11*746bf85eSottoint main() { 12*746bf85eSotto try { 13*746bf85eSotto f(); 14*746bf85eSotto } 15*746bf85eSotto catch (const ex & myex) { 16*746bf85eSotto std::cout << "Catching..." << std::endl; 17*746bf85eSotto exit(0); 18*746bf85eSotto } 19*746bf85eSotto exit(1); 20*746bf85eSotto } 21