Created on 2000-02-26.00:00:00 last changed 171 months ago
Rationale:
The LWG looked in some detail at all of the above mentioned algorithms, but believes that except for min_element() and max_element() it is already clear that last is returned if first == last.
Proposed resolution:
In [alg.min.max] - Minimum and maximum, paragraphs 7 and 9, append: Returns last if first==last.
The standard doesn't specify what min_element() and max_element() shall return if the range is empty (first equals last). The usual implementations return last. This problem seems also apply to partition(), stable_partition(), next_permutation(), and prev_permutation().
History | |||
---|---|---|---|
Date | User | Action | Args |
2010-10-21 18:28:33 | admin | set | messages: + msg1873 |
2010-10-21 18:28:33 | admin | set | messages: + msg1872 |
2000-02-26 00:00:00 | admin | create |