1 #ifndef _GLUCAT_TRY_CATCH_H 2 #define _GLUCAT_TRY_CATCH_H 56 catch (std::bad_alloc)
57 { std::cerr <<
"bad_alloc" << std::endl; }
59 { std::cerr <<
"unexpected exception" << std::endl; }
68 { result = (*f)(arg); }
71 catch (std::bad_alloc)
72 { std::cerr <<
"bad_alloc" << std::endl; }
74 { std::cerr <<
"unexpected exception" << std::endl; }
78 #endif // _GLUCAT_TRY_CATCH_H virtual void print_error_msg() const =0
int(* intintfn)(int)
For exception catching: pointer to function of int returning int.
int(* intfn)()
For exception catching: pointer to function returning int.
Abstract exception class.
int try_catch(intfn f)
Exception catching for functions returning int.