diff options
Diffstat (limited to 'libstdc++-v3/testsuite/ext/array_allocator')
-rw-r--r-- | libstdc++-v3/testsuite/ext/array_allocator/1.cc | 8 | ||||
-rw-r--r-- | libstdc++-v3/testsuite/ext/array_allocator/2.cc | 8 | ||||
-rw-r--r-- | libstdc++-v3/testsuite/ext/array_allocator/3.cc | 8 |
3 files changed, 15 insertions, 9 deletions
diff --git a/libstdc++-v3/testsuite/ext/array_allocator/1.cc b/libstdc++-v3/testsuite/ext/array_allocator/1.cc index 68cbc73f3f7..e0ea6f5ab13 100644 --- a/libstdc++-v3/testsuite/ext/array_allocator/1.cc +++ b/libstdc++-v3/testsuite/ext/array_allocator/1.cc @@ -25,9 +25,9 @@ // invalidate any other reasons why the executable file might be covered by // the GNU General Public License. -#include <cassert> #include <string> #include <ext/array_allocator.h> +#include <testsuite_hooks.h> typedef char char_type; typedef std::char_traits<char_type> traits_type; @@ -37,6 +37,8 @@ array_type extern_array; void test01() { + bool test __attribute__((unused)) = true; + using std::basic_string; typedef __gnu_cxx::array_allocator<char_type, array_type> allocator_type; typedef basic_string<char_type, traits_type, allocator_type> string_type; @@ -50,11 +52,11 @@ void test01() } catch(std::bad_alloc& obj) { - assert(true); + VERIFY( true ); } catch(...) { - assert(false); + VERIFY( false ); } } diff --git a/libstdc++-v3/testsuite/ext/array_allocator/2.cc b/libstdc++-v3/testsuite/ext/array_allocator/2.cc index 9ee2d07d554..74b2bc9a802 100644 --- a/libstdc++-v3/testsuite/ext/array_allocator/2.cc +++ b/libstdc++-v3/testsuite/ext/array_allocator/2.cc @@ -25,10 +25,10 @@ // invalidate any other reasons why the executable file might be covered by // the GNU General Public License. -#include <cassert> #include <string> #include <iostream> #include <ext/array_allocator.h> +#include <testsuite_hooks.h> typedef char char_type; typedef std::char_traits<char_type> traits_type; @@ -38,6 +38,8 @@ array_type extern_array; void test01() { + bool test __attribute__((unused)) = true; + using std::basic_string; typedef __gnu_cxx::array_allocator<char_type, array_type> allocator_type; typedef basic_string<char_type, traits_type, allocator_type> string_type; @@ -52,11 +54,11 @@ void test01() } catch(std::bad_alloc& obj) { - assert(false); + VERIFY( false ); } catch(...) { - assert(false); + VERIFY( false ); } s.append(1, 'c'); diff --git a/libstdc++-v3/testsuite/ext/array_allocator/3.cc b/libstdc++-v3/testsuite/ext/array_allocator/3.cc index 297b902c883..97ffbb467c5 100644 --- a/libstdc++-v3/testsuite/ext/array_allocator/3.cc +++ b/libstdc++-v3/testsuite/ext/array_allocator/3.cc @@ -25,9 +25,9 @@ // invalidate any other reasons why the executable file might be covered by // the GNU General Public License. -#include <cassert> #include <string> #include <ext/array_allocator.h> +#include <testsuite_hooks.h> typedef char char_type; typedef std::char_traits<char_type> traits_type; @@ -37,6 +37,8 @@ array_type extern_array; void test01() { + bool test __attribute__((unused)) = true; + using std::basic_string; typedef __gnu_cxx::array_allocator<char_type, array_type> allocator_type; typedef basic_string<char_type, traits_type, allocator_type> string_type; @@ -51,11 +53,11 @@ void test01() } catch(std::bad_alloc& obj) { - assert(true); + VERIFY( true ); } catch(...) { - assert(false); + VERIFY( false ); } } |