diff options
author | emsr <emsr@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-04-30 14:43:19 +0000 |
---|---|---|
committer | emsr <emsr@138bc75d-0d04-0410-961f-82ee72b054a4> | 2015-04-30 14:43:19 +0000 |
commit | 1f94878be8c21c18d4b221d384af79cbeafb8b99 (patch) | |
tree | cabf6ff1467f1bf41194a883662463c40fa44d6d /libstdc++-v3/include/experimental/map | |
parent | e087eb70718630c15027289fad62c891a05fc5c4 (diff) | |
download | gcc-1f94878be8c21c18d4b221d384af79cbeafb8b99.tar.gz |
2015-04-30 Edward Smith-Rowland <3dw4rd@verizon.net>
Add fundamentals TR container erasure.
* include/Makefile.am: Add new headers.
* include/Makefile.in: Add new headers.
* include/experimental/array: New.
* include/experimental/deque: New.
* include/experimental/erase_if.tcc: New.
* include/experimental/forward_list: New.
* include/experimental/list: New.
* include/experimental/map: New.
* include/experimental/set: New.
* include/experimental/string: New.
* include/experimental/unordered_map: New.
* include/experimental/unordered_set: New.
* include/experimental/vector: New.
* testsuite/experimental/deque/erasure.cc: New.
* testsuite/experimental/forward_list/erasure.cc: New.
* testsuite/experimental/list/erasure.cc: New.
* testsuite/experimental/map/erasure.cc: New.
* testsuite/experimental/set/erasure.cc: New.
* testsuite/experimental/string/erasure.cc: New.
* testsuite/experimental/unordered_map/erasure.cc: New.
* testsuite/experimental/unordered_set/erasure.cc: New.
* testsuite/experimental/vector/erasure.cc: New.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@222630 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/include/experimental/map')
-rw-r--r-- | libstdc++-v3/include/experimental/map | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/libstdc++-v3/include/experimental/map b/libstdc++-v3/include/experimental/map new file mode 100644 index 00000000000..c2b5a09e873 --- /dev/null +++ b/libstdc++-v3/include/experimental/map @@ -0,0 +1,68 @@ +// <experimental/map> -*- C++ -*- + +// Copyright (C) 2015 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 +// terms of the GNU General Public License as published by the +// Free Software Foundation; either version 3, or (at your option) +// any later version. + +// This library is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU General Public License for more details. + +// Under Section 7 of GPL version 3, you are granted additional +// permissions described in the GCC Runtime Library Exception, version +// 3.1, as published by the Free Software Foundation. + +// You should have received a copy of the GNU General Public License and +// a copy of the GCC Runtime Library Exception along with this program; +// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see +// <http://www.gnu.org/licenses/>. + +/** @file experimental/map + * This is a TS C++ Library header. + */ + +#ifndef _GLIBCXX_EXPERIMENTAL_MAP +#define _GLIBCXX_EXPERIMENTAL_MAP 1 + +#pragma GCC system_header + +#if __cplusplus <= 201103L +# include <bits/c++14_warning.h> +#else + +#include <map> +#include <experimental/erase_if.h> + +namespace std _GLIBCXX_VISIBILITY(default) +{ +namespace experimental +{ +inline namespace fundamentals_v2 +{ +_GLIBCXX_BEGIN_NAMESPACE_VERSION + + template<typename _Key, typename _Tp, typename _Compare, typename _Alloc, + typename _Predicate> + void + erase_if(map<_Key, _Tp, _Compare, _Alloc>& __cont, _Predicate __pred) + { __detail::__erase_nodes_if(__cont, __pred); } + + template<typename _Key, typename _Tp, typename _Compare, typename _Alloc, + typename _Predicate> + void + erase_if(multimap<_Key, _Tp, _Compare, _Alloc>& __cont, _Predicate __pred) + { __detail::__erase_nodes_if(__cont, __pred); } + +_GLIBCXX_END_NAMESPACE_VERSION +} // namespace fundamentals_v2 +} // namespace experimental +} // namespace std + +#endif // C++14 + +#endif // _GLIBCXX_EXPERIMENTAL_MAP |