Skip to content

Commit 96fce7b

Browse files
committed
[flat.*.{syn,erasure}] Change return type of erase_if to member size_type
All other containers and container adapters use the member size_type, and the flat maps already did so in the item specification, but not in the synopsis. The current wording follows the approved proposals, but this change seems like an improvement. Suggested by CD review feedback.
1 parent abd268b commit 96fce7b

File tree

1 file changed

+13
-8
lines changed

1 file changed

+13
-8
lines changed

source/containers.tex

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13244,7 +13244,8 @@
1324413244
// \ref{flat.map.erasure}, erasure for \tcode{flat_map}
1324513245
template<class Key, class T, class Compare, class KeyContainer, class MappedContainer,
1324613246
class Predicate>
13247-
size_t erase_if(flat_map<Key, T, Compare, KeyContainer, MappedContainer>& c, Predicate pred);
13247+
typename flat_map<Key, T, Compare, KeyContainer, MappedContainer>::size_type
13248+
erase_if(flat_map<Key, T, Compare, KeyContainer, MappedContainer>& c, Predicate pred);
1324813249

1324913250
// \ref{flat.multimap}, class template \tcode{flat_multimap}
1325013251
template<class Key, class T, class Compare = less<Key>,
@@ -13262,8 +13263,8 @@
1326213263
// \ref{flat.multimap.erasure}, erasure for \tcode{flat_multimap}
1326313264
template<class Key, class T, class Compare, class KeyContainer, class MappedContainer,
1326413265
class Predicate>
13265-
size_t erase_if(flat_multimap<Key, T, Compare, KeyContainer, MappedContainer>& c,
13266-
Predicate pred);
13266+
typename flat_multimap<Key, T, Compare, KeyContainer, MappedContainer>::size_type
13267+
erase_if(flat_multimap<Key, T, Compare, KeyContainer, MappedContainer>& c, Predicate pred);
1326713268
}
1326813269
\end{codeblock}
1326913270

@@ -13286,7 +13287,8 @@
1328613287

1328713288
// \ref{flat.set.erasure}, erasure for \tcode{flat_set}
1328813289
template<class Key, class Compare, class KeyContainer, class Predicate>
13289-
size_t erase_if(flat_set<Key, Compare, KeyContainer>& c, Predicate pred);
13290+
typename flat_set<Key, Compare, KeyContainer>::size_type
13291+
erase_if(flat_set<Key, Compare, KeyContainer>& c, Predicate pred);
1329013292

1329113293
// \ref{flat.multiset}, class template \tcode{flat_multiset}
1329213294
template<class Key, class Compare = less<Key>, class KeyContainer = vector<Key>>
@@ -13298,9 +13300,10 @@
1329813300
template<class Key, class Compare, class KeyContainer, class Allocator>
1329913301
struct uses_allocator<flat_multiset<Key, Compare, KeyContainer>, Allocator>;
1330013302

13301-
// \ref{flat.set.erasure}, erasure for \tcode{flat_multiset}
13303+
// \ref{flat.multiset.erasure}, erasure for \tcode{flat_multiset}
1330213304
template<class Key, class Compare, class KeyContainer, class Predicate>
13303-
size_t erase_if(flat_multiset<Key, Compare, KeyContainer>& c, Predicate pred);
13305+
typename flat_multiset<Key, Compare, KeyContainer>::size_type
13306+
erase_if(flat_multiset<Key, Compare, KeyContainer>& c, Predicate pred);
1330413307
}
1330513308
\end{codeblock}
1330613309

@@ -16808,7 +16811,8 @@
1680816811
\indexlibrarymember{erase_if}{flat_set}%
1680916812
\begin{itemdecl}
1681016813
template<class Key, class Compare, class KeyContainer, class Predicate>
16811-
size_t erase_if(flat_set<Key, Compare, KeyContainer>& c, Predicate pred);
16814+
typename flat_set<Key, Compare, KeyContainer>::size_type
16815+
erase_if(flat_set<Key, Compare, KeyContainer>& c, Predicate pred);
1681216816
\end{itemdecl}
1681316817

1681416818
\begin{itemdescr}
@@ -17362,7 +17366,8 @@
1736217366
\indexlibrarymember{erase_if}{flat_multiset}%
1736317367
\begin{itemdecl}
1736417368
template<class Key, class Compare, class KeyContainer, class Predicate>
17365-
size_t erase_if(flat_multiset<Key, Compare, KeyContainer>& c, Predicate pred);
17369+
typename flat_multiset<Key, Compare, KeyContainer>::size_type
17370+
erase_if(flat_multiset<Key, Compare, KeyContainer>& c, Predicate pred);
1736617371
\end{itemdecl}
1736717372

1736817373
\begin{itemdescr}

0 commit comments

Comments
 (0)