diff options
author | Paolo Carlini <pcarlini@suse.de> | 2007-05-22 22:43:22 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2007-05-22 22:43:22 +0000 |
commit | b0e94ec920230c1bdeaf395e9f4e7ec634e1ef29 (patch) | |
tree | cf48b7a376258c75925fe7e5a22a0772727521a8 | |
parent | 0a2acc8a59f838db412f32d3f73dd8e0f1dd6aea (diff) | |
download | gcc-b0e94ec920230c1bdeaf395e9f4e7ec634e1ef29.zip gcc-b0e94ec920230c1bdeaf395e9f4e7ec634e1ef29.tar.gz gcc-b0e94ec920230c1bdeaf395e9f4e7ec634e1ef29.tar.bz2 |
testsuite_allocator.h (check_new): Assign false to new_called.
2007-05-22 Paolo Carlini <pcarlini@suse.de>
* testsuite/util/testsuite_allocator.h (check_new): Assign false
to new_called.
(check_delete): Likewise for delete_called.
From-SVN: r124966
-rw-r--r-- | libstdc++-v3/ChangeLog | 6 | ||||
-rw-r--r-- | libstdc++-v3/testsuite/util/testsuite_allocator.h | 9 |
2 files changed, 12 insertions, 3 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 2c2ff95..0c66fea 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,9 @@ +2007-05-22 Paolo Carlini <pcarlini@suse.de> + + * testsuite/util/testsuite_allocator.h (check_new): Assign false + to new_called. + (check_delete): Likewise for delete_called. + 2007-05-21 Paolo Carlini <pcarlini@suse.de> * config/locale/gnu/c_locale.h: Do not include <cstdarg>, use builtins. diff --git a/libstdc++-v3/testsuite/util/testsuite_allocator.h b/libstdc++-v3/testsuite/util/testsuite_allocator.h index 51e4cf3..aaed731 100644 --- a/libstdc++-v3/testsuite/util/testsuite_allocator.h +++ b/libstdc++-v3/testsuite/util/testsuite_allocator.h @@ -1,7 +1,8 @@ // -*- C++ -*- // Testing allocator for the C++ library testsuite. // -// Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. +// Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 +// Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the @@ -41,8 +42,8 @@ namespace { - bool new_called = false; - bool delete_called = false; + bool new_called; + bool delete_called; }; namespace __gnu_test @@ -188,6 +189,7 @@ namespace __gnu_test check_new(Alloc a = Alloc()) { bool test __attribute__((unused)) = true; + new_called = false; a.allocate(10); test &= ( new_called == uses_global_new ); return test; @@ -198,6 +200,7 @@ namespace __gnu_test check_delete(Alloc a = Alloc()) { bool test __attribute__((unused)) = true; + delete_called = false; typename Alloc::pointer p = a.allocate(10); a.deallocate(p, 10); test &= ( delete_called == uses_global_delete ); |