PR libstdc++/64651
* libsupc++/exception_ptr.h (rethrow_exception): Add using-declaration
to __exception_ptr namespace.
* testsuite/18_support/exception_ptr/rethrow_exception.cc: Test ADL.
Remove unnecessary test variables.
From-SVN: r230147
+2015-11-11 Jonathan Wakely <jwakely@redhat.com>
+
+ PR libstdc++/64651
+ * libsupc++/exception_ptr.h (rethrow_exception): Add using-declaration
+ to __exception_ptr namespace.
+ * testsuite/18_support/exception_ptr/rethrow_exception.cc: Test ADL.
+ Remove unnecessary test variables.
+
2015-11-10 Jonathan Wakely <jwakely@redhat.com>
PR libstdc++/68190
namespace __exception_ptr
{
+ using std::rethrow_exception;
+
/**
* @brief An opaque pointer to an arbitrary exception.
* @ingroup exceptions
void test01()
{
- bool test __attribute__((unused)) = true;
using namespace std;
try {
void test03()
{
- bool test __attribute__((unused)) = true;
using namespace std;
exception_ptr ep;
void test04()
{
- bool test __attribute__((unused)) = true;
using namespace std;
// Weave the exceptions in an attempt to confuse the machinery.
}
}
+void test05()
+{
+ // libstdc++/64651 std::rethrow_exception not found by ADL
+ // This is not required to work but is a conforming extension.
+ try {
+ rethrow_exception(std::make_exception_ptr(0));
+ } catch(...) {
+ }
+}
+
int main()
{
test01();
test02();
test03();
test04();
+ test05();
return 0;
}