diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2016-12-02 21:43:36 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2016-12-02 21:43:36 +0000 |
commit | b126ca07d6526844f766a271a7b117c4273b652f (patch) | |
tree | 9ab52b3c1baa043ef1c12a3d7f2d1f5fce5476f5 | |
parent | f1636207ad8e142a11f80860ea27ea92fcc8c776 (diff) | |
download | libcxxabi-b126ca07d6526844f766a271a7b117c4273b652f.tar.gz |
Fix up r288457 for compilers that don't support noexcept function types:
disable the test entirely for those cases. This is a quick patch, I'll look at
a proper feature flag next.
git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@288539 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | test/catch_function_03.pass.cpp | 6 | ||||
-rw-r--r-- | test/catch_member_function_pointer_02.pass.cpp | 6 |
2 files changed, 8 insertions, 4 deletions
diff --git a/test/catch_function_03.pass.cpp b/test/catch_function_03.pass.cpp index c0b33fd..c366638 100644 --- a/test/catch_function_03.pass.cpp +++ b/test/catch_function_03.pass.cpp @@ -13,6 +13,7 @@ #include <cassert> +#ifdef __cpp_noexcept_function_type template<bool Noexcept> void f() noexcept(Noexcept) {} template<bool Noexcept> using FnType = void() noexcept(Noexcept); @@ -57,11 +58,12 @@ void check_deep() { int main() { -#ifdef __cpp_noexcept_function_type check<false, false>(); check<false, true>(); check<true, false>(); check<true, true>(); check_deep(); -#endif } +#else +int main() {} +#endif diff --git a/test/catch_member_function_pointer_02.pass.cpp b/test/catch_member_function_pointer_02.pass.cpp index 266337f..71df051 100644 --- a/test/catch_member_function_pointer_02.pass.cpp +++ b/test/catch_member_function_pointer_02.pass.cpp @@ -14,6 +14,7 @@ #include <cassert> +#ifdef __cpp_noexcept_function_type struct X { template<bool Noexcept> void f() noexcept(Noexcept) {} }; @@ -60,11 +61,12 @@ void check_deep() { int main() { -#ifdef __cpp_noexcept_function_type check<false, false>(); check<false, true>(); check<true, false>(); check<true, true>(); check_deep(); -#endif } +#else +int main() {} +#endif |