svn commit: r273381 - in head: contrib/libcxxrt lib/libcxxrt
Baptiste Daroussin
bapt at FreeBSD.org
Tue Oct 21 10:19:47 UTC 2014
Author: bapt
Date: Tue Oct 21 10:19:45 2014
New Revision: 273381
URL: https://svnweb.freebsd.org/changeset/base/273381
Log:
Add support for __cxa_throw_bad_array_new_length in libcxxrt
It is required for use with newer g++49
Differential Revision: https://reviews.freebsd.org/D982
Reviewed by: theraven
Approved by: theraven
MFC after: 3 weeks
Modified:
head/contrib/libcxxrt/auxhelper.cc
head/contrib/libcxxrt/stdexcept.cc
head/contrib/libcxxrt/stdexcept.h
head/lib/libcxxrt/Version.map
Modified: head/contrib/libcxxrt/auxhelper.cc
==============================================================================
--- head/contrib/libcxxrt/auxhelper.cc Tue Oct 21 09:14:16 2014 (r273380)
+++ head/contrib/libcxxrt/auxhelper.cc Tue Oct 21 10:19:45 2014 (r273381)
@@ -75,3 +75,8 @@ extern "C" void __cxa_deleted_virtual()
{
abort();
}
+
+extern "C" void __cxa_throw_bad_array_new_length()
+{
+ throw std::bad_array_new_length();
+}
Modified: head/contrib/libcxxrt/stdexcept.cc
==============================================================================
--- head/contrib/libcxxrt/stdexcept.cc Tue Oct 21 09:14:16 2014 (r273380)
+++ head/contrib/libcxxrt/stdexcept.cc Tue Oct 21 10:19:45 2014 (r273381)
@@ -82,5 +82,13 @@ const char* bad_typeid::what() const thr
return "std::bad_typeid";
}
+bad_array_new_length::bad_array_new_length() throw() {}
+bad_array_new_length::~bad_array_new_length() {}
+bad_array_new_length::bad_array_new_length(const bad_array_new_length&) throw() {}
+bad_array_new_length& bad_array_new_length::operator=(const bad_array_new_length&) throw()
+{
+ return *this;
+}
+
} // namespace std
Modified: head/contrib/libcxxrt/stdexcept.h
==============================================================================
--- head/contrib/libcxxrt/stdexcept.h Tue Oct 21 09:14:16 2014 (r273380)
+++ head/contrib/libcxxrt/stdexcept.h Tue Oct 21 10:19:45 2014 (r273381)
@@ -81,6 +81,15 @@ namespace std
virtual const char* what() const throw();
};
+ class bad_array_new_length: public exception
+ {
+ public:
+ bad_array_new_length() throw();
+ bad_array_new_length(const bad_array_new_length&) throw();
+ bad_array_new_length& operator=(const bad_array_new_length&) throw();
+ virtual ~bad_array_new_length();
+ virtual const char *what() const throw();
+ };
} // namespace std
Modified: head/lib/libcxxrt/Version.map
==============================================================================
--- head/lib/libcxxrt/Version.map Tue Oct 21 09:14:16 2014 (r273380)
+++ head/lib/libcxxrt/Version.map Tue Oct 21 10:19:45 2014 (r273381)
@@ -26,6 +26,7 @@ CXXABI_1.3 {
__cxa_pure_virtual;
__cxa_rethrow;
__cxa_throw;
+ __cxa_throw_bad_array_new_length;
__cxa_type_match;
__cxa_vec_cctor;
__cxa_vec_cleanup;
@@ -273,6 +274,9 @@ CXXRT_1.0 {
"std::bad_alloc::bad_alloc(std::bad_alloc const&)";
"std::bad_alloc::bad_alloc()";
"std::bad_alloc::operator=(std::bad_alloc const&)";
+ "std::bad_array_new_length::bad_array_new_length(std::bad_array_new_length const&)";
+ "std::bad_array_new_length::bad_array_new_length()";
+ "std::bad_array_new_length::operator=(std::bad_array_new_length const&)";
};
__cxa_allocate_dependent_exception;
@@ -307,6 +311,7 @@ GLIBCXX_3.4 {
"std::bad_typeid::~bad_typeid()";
"std::exception::~exception()";
"std::bad_alloc::~bad_alloc()";
+ "std::bad_array_new_length::~bad_array_new_length()";
"std::exception::what() const";
@@ -320,17 +325,20 @@ GLIBCXX_3.4 {
"vtable for std::bad_typeid";
"vtable for std::exception";
"vtable for std::type_info";
+ "vtable for std::bad_array_new_length";
"typeinfo for std::bad_alloc";
"typeinfo for std::bad_typeid";
"typeinfo for std::bad_cast";
"typeinfo for std::exception";
"typeinfo for std::type_info";
+ "typeinfo for std::bad_array_new_length";
"typeinfo name for std::bad_alloc";
"typeinfo name for std::bad_typeid";
"typeinfo name for std::bad_cast";
"typeinfo name for std::exception";
"typeinfo name for std::type_info";
+ "typeinfo name for std::bad_array_new_length";
};
};
@@ -340,6 +348,7 @@ GLIBCXX_3.4.9 {
"std::bad_typeid::what() const";
"std::bad_cast::what() const";
"std::bad_alloc::what() const";
+ "std::bad_array_new_length::what() const";
};
} GLIBCXX_3.4;
More information about the svn-src-all
mailing list