P0458R2 Checking for Existence of an Element in Associative Containers
commitbe7ce8060622c36c386030f1e6aecff48e6cd825
authorredi <redi@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 4 Jul 2018 18:16:26 +0000 (4 18:16 +0000)
committerredi <redi@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 4 Jul 2018 18:16:26 +0000 (4 18:16 +0000)
tree3aa975a42e473815b8d7e5e6dcfe2b83da0003c4
parentc44e86a535c571347c0792f8117079c92d1a607f
P0458R2 Checking for Existence of an Element in Associative Containers

* include/bits/stl_map.h (map::contains): Add for C++2a.
* include/bits/stl_multimap.h (multimap::contains): Likewise.
* include/bits/stl_multiset.h (multiset::contains): Likewise.
* include/bits/stl_set.h (set::contains): Likewise.
* include/bits/stl_tree.h (__has_is_transparent_t): Define alias.
(_Rb_tree::_M_find_tr, _Rb_tree::_M_count_tr)
(_Rb_tree::_M_lower_bound_tr, _Rb_tree::_M_upper_bound_tr)
(_Rb_tree::_M_equal_range_tr): Use __has_is_transparent_t.
* include/bits/unordered_map.h (unordered_map::contains)
(unordered_multimap::contains): Add for C++2a.
* include/bits/unordered_set.h (unordered_set::contains)
(unordered_multiset::contains): Likewise.
* testsuite/23_containers/map/operations/contains.cc: New.
* testsuite/23_containers/multimap/operations/contains.cc: New.
* testsuite/23_containers/multiset/operations/contains.cc: New.
* testsuite/23_containers/set/operations/contains.cc: New.
* testsuite/23_containers/unordered_map/operations/contains.cc: New.
* testsuite/23_containers/unordered_multimap/operations/contains.cc:
New.
* testsuite/23_containers/unordered_multiset/operations/contains.cc:
New.
* testsuite/23_containers/unordered_set/operations/contains.cc: New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@262418 138bc75d-0d04-0410-961f-82ee72b054a4
16 files changed:
libstdc++-v3/ChangeLog
libstdc++-v3/include/bits/stl_map.h
libstdc++-v3/include/bits/stl_multimap.h
libstdc++-v3/include/bits/stl_multiset.h
libstdc++-v3/include/bits/stl_set.h
libstdc++-v3/include/bits/stl_tree.h
libstdc++-v3/include/bits/unordered_map.h
libstdc++-v3/include/bits/unordered_set.h
libstdc++-v3/testsuite/23_containers/map/operations/contains.cc [new file with mode: 0644]
libstdc++-v3/testsuite/23_containers/multimap/operations/contains.cc [new file with mode: 0644]
libstdc++-v3/testsuite/23_containers/multiset/operations/contains.cc [new file with mode: 0644]
libstdc++-v3/testsuite/23_containers/set/operations/contains.cc [new file with mode: 0644]
libstdc++-v3/testsuite/23_containers/unordered_map/operations/contains.cc [new file with mode: 0644]
libstdc++-v3/testsuite/23_containers/unordered_multimap/operations/contains.cc [new file with mode: 0644]
libstdc++-v3/testsuite/23_containers/unordered_multiset/operations/contains.cc [new file with mode: 0644]
libstdc++-v3/testsuite/23_containers/unordered_set/operations/contains.cc [new file with mode: 0644]