forked from p12tic/cppreference-doc
-
Notifications
You must be signed in to change notification settings - Fork 57
Expand file tree
/
Copy pathstdexcept
More file actions
101 lines (81 loc) · 2.59 KB
/
stdexcept
File metadata and controls
101 lines (81 loc) · 2.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
/* Copyright (C) 2015 Povilas Kanapickas <povilas@radix.lt>
This file is part of cppreference-doc
This work is licensed under the Creative Commons Attribution-ShareAlike 3.0
Unported License. To view a copy of this license, visit
http://creativecommons.org/licenses/by-sa/3.0/ or send a letter to Creative
Commons, 444 Castro Street, Suite 900, Mountain View, California, 94041, USA.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.3 or
any later version published by the Free Software Foundation; with no
Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
*/
#ifndef CPPREFERENCE_STDEXCEPT_H
#define CPPREFERENCE_STDEXCEPT_H
#include <exception>
#include <detail/string_fwd>
namespace std {
class logic_error : public exception {
public:
explicit logic_error(const string& what_arg);
#if CPPREFERENCE_STDVER>= 2011
explicit logic_error(const char* what_arg);
#endif
};
class domain_error : public logic_error {
public:
explicit domain_error(const string& what_arg);
#if CPPREFERENCE_STDVER>= 2011
explicit domain_error(const char* what_arg);
#endif
};
class invalid_argument : public logic_error {
public:
explicit invalid_argument(const string& what_arg);
#if CPPREFERENCE_STDVER>= 2011
explicit invalid_argument(const char* what_arg);
#endif
};
class length_error : public logic_error {
public:
explicit length_error(const string& what_arg);
#if CPPREFERENCE_STDVER>= 2011
explicit length_error(const char* what_arg);
#endif
};
class out_of_range : public logic_error {
public:
explicit out_of_range(const string& what_arg);
#if CPPREFERENCE_STDVER>= 2011
explicit out_of_range(const char* what_arg);
#endif
};
class runtime_error : public exception {
public:
explicit runtime_error(const string& what_arg);
#if CPPREFERENCE_STDVER>= 2011
explicit runtime_error(const char* what_arg);
#endif
};
class range_error : public runtime_error {
public:
explicit range_error(const string& what_arg);
#if CPPREFERENCE_STDVER>= 2011
explicit range_error(const char* what_arg);
#endif
};
class overflow_error : public runtime_error {
public:
explicit overflow_error(const string& what_arg);
#if CPPREFERENCE_STDVER>= 2011
explicit overflow_error(const char* what_arg);
#endif
};
class underflow_error : public runtime_error {
public:
explicit underflow_error(const string& what_arg);
#if CPPREFERENCE_STDVER>= 2011
explicit underflow_error(const char* what_arg);
#endif
};
} // namespace std
#endif // CPPREFERENCE_STDEXCEPT_H