aboutsummaryrefslogtreecommitdiff
path: root/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/default_ctor.pass.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/default_ctor.pass.cpp')
-rw-r--r--test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/default_ctor.pass.cpp9
1 files changed, 2 insertions, 7 deletions
diff --git a/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/default_ctor.pass.cpp b/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/default_ctor.pass.cpp
index 0573ef862efd..f6a97ef92d84 100644
--- a/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/default_ctor.pass.cpp
+++ b/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.nonvirtuals/default_ctor.pass.cpp
@@ -7,6 +7,7 @@
//
//===----------------------------------------------------------------------===//
+// UNSUPPORTED: c++98, c++03, c++11
// <system_error>
// class error_category
@@ -18,23 +19,17 @@
#include <string>
#include <cassert>
-#if _LIBCPP_STD_VER > 11
-
class test1
: public std::error_category
{
public:
constexpr test1() = default; // won't compile if error_category() is not constexpr
virtual const char* name() const noexcept {return nullptr;}
- virtual std::string message(int ev) const {return std::string();}
+ virtual std::string message(int) const {return std::string();}
};
-#endif // _LIBCPP_STD_VER > 11
-
int main()
{
-#if _LIBCPP_STD_VER > 11
static_assert(std::is_nothrow_default_constructible<test1>::value,
"error_category() must exist and be noexcept");
-#endif // _LIBCPP_STD_VER > 11
}