diff options
Diffstat (limited to 'test/std/language.support/support.exception')
4 files changed, 9 insertions, 27 deletions
diff --git a/test/std/language.support/support.exception/except.nested/rethrow_if_nested.pass.cpp b/test/std/language.support/support.exception/except.nested/rethrow_if_nested.pass.cpp index a8b6e15feab88..4ee95fdf30016 100644 --- a/test/std/language.support/support.exception/except.nested/rethrow_if_nested.pass.cpp +++ b/test/std/language.support/support.exception/except.nested/rethrow_if_nested.pass.cpp @@ -76,9 +76,9 @@ int main() std::rethrow_if_nested(a); assert(false); } - catch (const B& b) + catch (const B& b2) { - assert(b == B(5)); + assert(b2 == B(5)); } } } diff --git a/test/std/language.support/support.exception/except.nested/throw_with_nested.pass.cpp b/test/std/language.support/support.exception/except.nested/throw_with_nested.pass.cpp index 98006bb1e3a0f..c14cb69bdea3d 100644 --- a/test/std/language.support/support.exception/except.nested/throw_with_nested.pass.cpp +++ b/test/std/language.support/support.exception/except.nested/throw_with_nested.pass.cpp @@ -18,6 +18,8 @@ #include <cstdlib> #include <cassert> +#include "test_macros.h" + class A { int data_; @@ -37,7 +39,7 @@ public: friend bool operator==(const B& x, const B& y) {return x.data_ == y.data_;} }; -#if __cplusplus > 201103L +#if TEST_STD_VER > 11 struct Final final {}; #endif @@ -105,14 +107,14 @@ int main() assert(i == 7); } } -#if __cplusplus > 201103L +#if TEST_STD_VER > 11 { try { std::throw_with_nested(Final()); assert(false); } - catch (const Final &f) + catch (const Final &) { } } diff --git a/test/std/language.support/support.exception/propagation/current_exception.pass.cpp b/test/std/language.support/support.exception/propagation/current_exception.pass.cpp index 09adf580bddf8..7bf1df457dbed 100644 --- a/test/std/language.support/support.exception/propagation/current_exception.pass.cpp +++ b/test/std/language.support/support.exception/propagation/current_exception.pass.cpp @@ -74,7 +74,7 @@ int main() throw A(); assert(false); } - catch (A& a) + catch (A&) { std::exception_ptr p = std::current_exception(); assert(A::constructed == 1); @@ -94,7 +94,7 @@ int main() throw A(); assert(false); } - catch (A a) + catch (A) { std::exception_ptr p = std::current_exception(); assert(A::constructed == 2); diff --git a/test/std/language.support/support.exception/version.pass.cpp b/test/std/language.support/support.exception/version.pass.cpp deleted file mode 100644 index acdedbb31fe32..0000000000000 --- a/test/std/language.support/support.exception/version.pass.cpp +++ /dev/null @@ -1,20 +0,0 @@ -//===----------------------------------------------------------------------===// -// -// The LLVM Compiler Infrastructure -// -// This file is dual licensed under the MIT and the University of Illinois Open -// Source Licenses. See LICENSE.TXT for details. -// -//===----------------------------------------------------------------------===// - -// <exception> - -#include <exception> - -#ifndef _LIBCPP_VERSION -#error _LIBCPP_VERSION not defined -#endif - -int main() -{ -} |