diff options
| author | redi <redi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-04-25 18:03:03 +0000 |
|---|---|---|
| committer | redi <redi@138bc75d-0d04-0410-961f-82ee72b054a4> | 2012-04-25 18:03:03 +0000 |
| commit | 106b97d332f143002ea975acdb1485068e2c992d (patch) | |
| tree | 28099b063a68faa1527cf3db21bb956881137c82 /libstdc++-v3/include/std/scoped_allocator | |
| parent | 052166fd4a8051c7dc4c87d408be091c99aafd55 (diff) | |
| download | ppe42-gcc-106b97d332f143002ea975acdb1485068e2c992d.tar.gz ppe42-gcc-106b97d332f143002ea975acdb1485068e2c992d.zip | |
* include/std/scoped_allocator (scoped_allocator::__outermost): Do
not pass non-POD to varargs function.
* testsuite/20_util/scoped_allocator/1.cc: Fix test.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@186836 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/include/std/scoped_allocator')
| -rw-r--r-- | libstdc++-v3/include/std/scoped_allocator | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libstdc++-v3/include/std/scoped_allocator b/libstdc++-v3/include/std/scoped_allocator index edace9840d1..fc2db7cbd66 100644 --- a/libstdc++-v3/include/std/scoped_allocator +++ b/libstdc++-v3/include/std/scoped_allocator @@ -1,6 +1,6 @@ // <scoped_allocator> -*- C++ -*- -// Copyright (C) 2011 Free Software Foundation, Inc. +// Copyright (C) 2011, 2012 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 @@ -77,7 +77,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION template<typename _Alloc> inline auto - __do_outermost(_Alloc& __a, _Alloc&) -> decltype(__a.outer_allocator()) + __do_outermost(_Alloc& __a, _Alloc*) -> decltype(__a.outer_allocator()) { return __a.outer_allocator(); } template<typename _Alloc> @@ -87,8 +87,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION template<typename _Alloc> inline auto - __outermost(_Alloc& __a) -> decltype(__do_outermost(__a, __a)) - { return __do_outermost(__a, __a); } + __outermost(_Alloc& __a) -> decltype(__do_outermost(__a, &__a)) + { return __do_outermost(__a, &__a); } template<typename _OuterAlloc, typename... _InnerAllocs> class scoped_allocator_adaptor; |

