Line data Source code
1 : //
2 : // Copyright (c) 2019 Vinnie Falco (vinnie.falco@gmail.com)
3 : //
4 : // Distributed under the Boost Software License, Version 1.0. (See accompanying
5 : // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6 : //
7 : // Official repository: https://github.com/cppalliance/capy
8 : //
9 :
10 : #ifndef BOOST_CAPY_DETAIL_EXCEPT_HPP
11 : #define BOOST_CAPY_DETAIL_EXCEPT_HPP
12 :
13 : #include <boost/capy/detail/config.hpp>
14 : #include <boost/assert/source_location.hpp>
15 : #include <boost/core/detail/string_view.hpp>
16 : #include <boost/system/error_code.hpp>
17 :
18 : namespace boost {
19 : namespace capy {
20 : namespace detail {
21 :
22 : BOOST_CAPY_DECL void BOOST_NORETURN throw_bad_typeid(
23 1 : source_location const& loc = BOOST_CURRENT_LOCATION);
24 :
25 : BOOST_CAPY_DECL void BOOST_NORETURN throw_bad_alloc(
26 : source_location const& loc = BOOST_CURRENT_LOCATION);
27 :
28 : BOOST_CAPY_DECL void BOOST_NORETURN throw_invalid_argument(
29 9 : source_location const& loc = BOOST_CURRENT_LOCATION);
30 :
31 : BOOST_CAPY_DECL void BOOST_NORETURN throw_invalid_argument(
32 : char const* what,
33 4 : source_location const& loc = BOOST_CURRENT_LOCATION);
34 :
35 : BOOST_CAPY_DECL void BOOST_NORETURN throw_length_error(
36 1 : source_location const& loc = BOOST_CURRENT_LOCATION);
37 :
38 : BOOST_CAPY_DECL void BOOST_NORETURN throw_length_error(
39 : char const* what,
40 : source_location const& loc = BOOST_CURRENT_LOCATION);
41 :
42 : BOOST_CAPY_DECL void BOOST_NORETURN throw_logic_error(
43 : source_location const& loc = BOOST_CURRENT_LOCATION);
44 :
45 : BOOST_CAPY_DECL void BOOST_NORETURN throw_out_of_range(
46 : source_location const& loc = BOOST_CURRENT_LOCATION);
47 :
48 : BOOST_CAPY_DECL void BOOST_NORETURN throw_runtime_error(
49 : char const* what,
50 : source_location const& loc = BOOST_CURRENT_LOCATION);
51 :
52 : BOOST_CAPY_DECL void BOOST_NORETURN throw_system_error(
53 : system::error_code const& ec,
54 7 : source_location const& loc = BOOST_CURRENT_LOCATION);
55 :
56 : } // detail
57 : } // capy
58 : } // boost
59 :
60 : #endif
|