Usermode/libc++ - Exception handling in progress (build broken)
[tpg/acess2.git] / Usermode / Libraries / libc++.so_src / exceptions.cc
1 /*
2  * Acess2 C++ Library
3  * - By John Hodge (thePowersGang)
4  *
5  * exceptions.cc
6  * - ::std::exception and friends
7  */
8 #include <string>
9 #include <exception>
10 #include <stdexcept>
11
12 // === CODE ===
13 ::std::exception::exception() throw():
14         m_what_str("-empty-")
15 {
16 }
17 ::std::exception::exception(const exception& other) throw():
18         m_what_str(other.m_what_str)
19 {
20 }
21 ::std::exception::exception(const string& str) throw():
22         m_what_str(str)
23 {
24 }
25 ::std::exception& ::std::exception::operator=(const exception& other) throw()
26 {
27         m_what_str = other.m_what_str;
28         return *this;
29 }
30 ::std::exception::~exception() throw()
31 {
32 }
33 const char* ::std::exception::what() const throw()
34 {
35         return m_what_str.c_str();
36 }
37
38 ::std::logic_error::logic_error(const ::std::string& what_str):
39         exception(what_str)
40 {
41 }
42
43 ::std::out_of_range::out_of_range(const ::std::string& what_str):
44         logic_error(what_str)
45 {
46 }

UCC git Repository :: git.ucc.asn.au