1 /** 2 * stdexcept.cc - provides stub implementations of the exceptions required by the runtime. 3 */ 4 #include "stdexcept.h" 5 6 namespace std { 7 8 exception::exception() throw() {} 9 exception::~exception() {} 10 exception::exception(const exception&) throw() {} 11 exception& exception::operator=(const exception&) throw() 12 { 13 return *this; 14 } 15 const char* exception::what() const throw() 16 { 17 return "std::exception"; 18 } 19 20 bad_alloc::bad_alloc() throw() {} 21 bad_alloc::~bad_alloc() {} 22 bad_alloc::bad_alloc(const bad_alloc&) throw() {} 23 bad_alloc& bad_alloc::operator=(const bad_alloc&) throw() 24 { 25 return *this; 26 } 27 const char* bad_alloc::what() const throw() 28 { 29 return "cxxrt::bad_alloc"; 30 } 31 32 33 34 bad_cast::bad_cast() throw() {} 35 bad_cast::~bad_cast() {} 36 bad_cast::bad_cast(const bad_cast&) throw() {} 37 bad_cast& bad_cast::operator=(const bad_cast&) throw() 38 { 39 return *this; 40 } 41 const char* bad_cast::what() const throw() 42 { 43 return "std::bad_cast"; 44 } 45 46 bad_typeid::bad_typeid() throw() {} 47 bad_typeid::~bad_typeid() {} 48 bad_typeid::bad_typeid(const bad_typeid &__rhs) throw() {} 49 bad_typeid& bad_typeid::operator=(const bad_typeid &__rhs) throw() 50 { 51 return *this; 52 } 53 54 const char* bad_typeid::what() const throw() 55 { 56 return "std::bad_typeid"; 57 } 58 59 } // namespace std 60 61