• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //Copyright (c) 2006-2009 Emil Dotchevski and Reverge Studios, Inc.
2 
3 //Distributed under the Boost Software License, Version 1.0. (See accompanying
4 //file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
5 
6 #define BOOST_NO_EXCEPTIONS
7 
8 #include <boost/throw_exception.hpp>
9 #include <cstdlib>
10 
11 #if defined(_MSC_VER)
12 # pragma warning(disable: 4702) // unreachable code
13 #endif
14 
15 class my_exception: public std::exception {};
16 
main()17 int main()
18 {
19     boost::throw_exception( my_exception() );
20     return 1;
21 }
22 
23 namespace boost
24 {
25 
throw_exception(std::exception const &)26 void throw_exception( std::exception const & )
27 {
28     std::exit( 0 );
29 }
30 
31 } // namespace boost
32