]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
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 | #define BOOST_EXCEPTION_DISABLE | |
92f5a8d4 | 8 | |
7c673cae | 9 | #include <boost/throw_exception.hpp> |
92f5a8d4 TL |
10 | #include <cstdlib> |
11 | ||
f67539c2 TL |
12 | #if defined(_MSC_VER) |
13 | # pragma warning(disable: 4702) // unreachable code | |
14 | #endif | |
15 | ||
92f5a8d4 TL |
16 | class my_exception: public std::exception {}; |
17 | ||
18 | int main() | |
19 | { | |
20 | boost::throw_exception( my_exception() ); | |
21 | return 1; | |
22 | } | |
23 | ||
24 | namespace boost | |
25 | { | |
26 | ||
27 | void throw_exception( std::exception const & ) | |
28 | { | |
29 | std::exit( 0 ); | |
30 | } | |
31 | ||
32 | } // namespace boost |