From 0c605bf32f4b323ef25ce9b4d953906f3a266545 Mon Sep 17 00:00:00 2001 From: Peter Dimov Date: Wed, 5 Sep 2018 20:45:51 +0300 Subject: [PATCH] MacOS doesn't have quick_exit; Cygwin doesn't declare it in C++03 mode --- include/boost/core/quick_exit.hpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/include/boost/core/quick_exit.hpp b/include/boost/core/quick_exit.hpp index c001107..5c2e7bb 100644 --- a/include/boost/core/quick_exit.hpp +++ b/include/boost/core/quick_exit.hpp @@ -18,6 +18,12 @@ #include #include +#if defined(__CYGWIN__) && __cplusplus < 201103L + +extern "C" _Noreturn void quick_exit(int); + +#endif + namespace boost { @@ -27,6 +33,10 @@ BOOST_NORETURN void quick_exit( int code ) BOOST_NOEXCEPT ::_exit( code ); +#elif defined(__APPLE__) + + ::_Exit( code ); + #else ::quick_exit( code );