summaryrefslogtreecommitdiffstats
path: root/src/boost/libs/histogram/test/throw_exception.hpp
blob: e0160ed7e602af84d7c532ca75c5190000c5b0be (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// Copyright 2019 Hans Dembinski
//
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt
// or copy at http://www.boost.org/LICENSE_1_0.txt)

#ifdef BOOST_NO_EXCEPTIONS

#include <cstdlib> // std::abort
#include <exception>
#include <iostream>

namespace boost {
// dummy implementation for user-defined function from boost/throw_exception.hpp
inline void throw_exception(std::exception const& e) {
  std::cerr << e.what() << std::endl;
  std::abort();
}
} // namespace boost

#endif