Skip these tests under libcpp-no-exceptions.
Differential Revision: https://reviews.llvm.org/D26141
llvm-svn: 285677
//
//===----------------------------------------------------------------------===//
-// XFAIL: libcpp-no-exceptions
// <random>
// class random_device;
}
void check_random_device_invalid(const std::string &token) {
+#ifndef TEST_HAS_NO_EXCEPTIONS
try {
std::random_device r(token);
LIBCPP_ASSERT(false);
} catch (const std::system_error&) {
}
+#endif
}
//
//===----------------------------------------------------------------------===//
-// XFAIL: libcpp-no-exceptions
// <random>
// class random_device;
std::random_device::result_type e = r();
}
+#ifndef TEST_HAS_NO_EXCEPTIONS
try
{
std::random_device r("/dev/null");
catch (const std::system_error&)
{
}
+#endif
}