Title
std::includes should require CopyConstructible predicate
Status
nad concepts
Section
[includes]
Submitter
Alisdair Meredith

Created on 2009-04-28.00:00:00 last changed 164 months ago

Messages

Date: 2010-10-21.18:28:33

Proposed resolution:

Change [algorithms.syn] and [includes]:

template<InputIterator Iter1, InputIterator Iter2,
         typename CopyConstructible Compare>
  requires Predicate<Compare, Iter1::value_type, Iter2::value_type>
        && Predicate<Compare, Iter2::value_type, Iter1::value_type>
  bool includes(Iter1 first1, Iter1 last1,
                Iter2 first2, Iter2 last2,
                Compare comp);
Date: 2010-10-21.18:28:33

[ Batavia (2009-05): ]

We agree with the proposed resolution. Move to NAD Editorial.

Date: 2009-04-28.00:00:00

All the set operation algorithms require a CopyConstructible predicate, with the exception of std::includes. This looks like a typo as much as anything, given the general library requirement that predicates are copy constructible, and wording style of other set-like operations.

History
Date User Action Args
2010-10-21 18:28:33adminsetmessages: + msg762
2010-10-21 18:28:33adminsetmessages: + msg761
2009-04-28 00:00:00admincreate