Files
cppdraft_translate/cppdraft/associative/map/syn.md
2025-10-25 03:02:53 +03:00

18 lines
2.8 KiB
Markdown
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

[associative.map.syn]
# 23 Containers library [[containers]](./#containers)
## 23.4 Associative containers [[associative]](associative#map.syn)
### 23.4.2 Header <map> synopsis [associative.map.syn]
[🔗](#header:%3cmap%3e)
#include <compare> // see [[compare.syn]](compare.syn "17.12.1Header <compare> synopsis")#include <initializer_list> // see [[initializer.list.syn]](initializer.list.syn "17.11.2Header <initializer_­list> synopsis")namespace std {// [[map]](map "23.4.3Class template map"), class template maptemplate<class Key, class T, class Compare = less<Key>, class Allocator = allocator<pair<const Key, T>>>class map; template<class Key, class T, class Compare, class Allocator>constexpr bool operator==(const map<Key, T, Compare, Allocator>& x, const map<Key, T, Compare, Allocator>& y); template<class Key, class T, class Compare, class Allocator>constexpr *synth-three-way-result*<pair<const Key, T>>operator<=>(const map<Key, T, Compare, Allocator>& x, const map<Key, T, Compare, Allocator>& y); template<class Key, class T, class Compare, class Allocator>constexpr void swap(map<Key, T, Compare, Allocator>& x,
map<Key, T, Compare, Allocator>& y)noexcept(noexcept(x.swap(y))); // [[map.erasure]](map.erasure "23.4.3.5Erasure"), erasure for maptemplate<class Key, class T, class Compare, class Allocator, class Predicate>constexpr typename map<Key, T, Compare, Allocator>::size_type
erase_if(map<Key, T, Compare, Allocator>& c, Predicate pred); // [[multimap]](multimap "23.4.4Class template multimap"), class template multimaptemplate<class Key, class T, class Compare = less<Key>, class Allocator = allocator<pair<const Key, T>>>class multimap; template<class Key, class T, class Compare, class Allocator>constexpr bool operator==(const multimap<Key, T, Compare, Allocator>& x, const multimap<Key, T, Compare, Allocator>& y); template<class Key, class T, class Compare, class Allocator>constexpr *synth-three-way-result*<pair<const Key, T>>operator<=>(const multimap<Key, T, Compare, Allocator>& x, const multimap<Key, T, Compare, Allocator>& y); template<class Key, class T, class Compare, class Allocator>constexpr void swap(multimap<Key, T, Compare, Allocator>& x,
multimap<Key, T, Compare, Allocator>& y)noexcept(noexcept(x.swap(y))); // [[multimap.erasure]](multimap.erasure "23.4.4.4Erasure"), erasure for multimaptemplate<class Key, class T, class Compare, class Allocator, class Predicate>constexpr typename multimap<Key, T, Compare, Allocator>::size_type
erase_if(multimap<Key, T, Compare, Allocator>& c, Predicate pred); namespace pmr {template<class Key, class T, class Compare = less<Key>>using map = std::map<Key, T, Compare,
polymorphic_allocator<pair<const Key, T>>>; template<class Key, class T, class Compare = less<Key>>using multimap = std::multimap<Key, T, Compare,
polymorphic_allocator<pair<const Key, T>>>; }}