2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.eh / terminate2.C
blob3a3115843e7c00bac1627f833c8ae34894a80fcc
1 // { dg-do run  }
2 // Test that an unhandled exception causes us to call terminate.
4 #include <exception>
5 #include <cstdlib>
7 void my_terminate ()
9   std::exit (0);
12 int main (void)
14   std::set_terminate (my_terminate);
15   throw 1;
16   return 1;