Title
Remove IsSameType hold-over constraints
Status
nad editorial
Section
[alg.min.max]
Submitter
Alisdair Meredith

Created on 2009-03-11.00:00:00 last changed 171 months ago

Messages

Date: 2010-10-21.18:28:33

Proposed resolution:

Change [algorithms]:

template<class T, StrictWeakOrder<auto, T> Compare>
  requires !SameType<T, Compare> && CopyConstructible<Compare>
  const T& min(const T& a, const T& b, Compare comp);
...
template<class T, StrictWeakOrder<auto, T> Compare>
  requires !SameType<T, Compare> && CopyConstructible<Compare>
  const T& max(const T& a, const T& b, Compare comp);
...
template<class T, StrictWeakOrder<auto, T> Compare>
  requires !SameType<T, Compare> && CopyConstructible<Compare>
  pair<const T&, const T&> minmax(const T& a, const T& b, Compare comp);

Change [alg.min.max], p1, p9 and p17:

template<class T, StrictWeakOrder<auto, T> Compare>
  requires !SameType<T, Compare> && CopyConstructible<Compare>
  const T& min(const T& a, const T& b, Compare comp);
...
template<class T, StrictWeakOrder<auto, T> Compare>
  requires !SameType<T, Compare> && CopyConstructible<Compare>
  const T& max(const T& a, const T& b, Compare comp);
...
template<class T, StrictWeakOrder<auto, T> Compare>
  requires !SameType<T, Compare> && CopyConstructible<Compare>
  pair<const T&, const T&> minmax(const T& a, const T& b, Compare comp);
Date: 2010-10-21.18:28:33

[ 2009-07 Frankfurt ]

We believe this is NAD, but this needs to be reviewed against the post-remove-concepts draft.

Date: 2010-10-21.18:28:33

[ Batavia (2009-05): ]

We agree with the proposed resolution. Move to Tentatively Ready.

Date: 2009-03-11.00:00:00

Addresses UK 305

The negative requirement on IsSameType is a hold-over from an earlier draught with a variadic template form of min/max algorith. It is no longer necessary.

History
Date User Action Args
2010-10-21 18:28:33adminsetmessages: + msg323
2010-10-21 18:28:33adminsetmessages: + msg322
2010-10-21 18:28:33adminsetmessages: + msg321
2009-03-11 00:00:00admincreate