[libc++] Remove incorrect default constructor in cpp17_input_iterator
AFAICT, Cpp17InputIterators are not required to be default constructible, since that requirement is added in Cpp17ForwardIterator. Hence, our archetype for Cpp17InputIterator should not be default constructible. Removing that constructor has a ripple effect on a couple of tests that were making incorrect assumptions. Notably: - Some tests were using cpp17_input_iterator as a sentinel for itself. That is not valid, because a cpp17_input_iterator is not semiregular anymore after the change (and hence it doesn't satisfy sentinel_for). - Some tests were using a stride-counted cpp17_input_iterator as the sentinel for a range. This doesn't work anymore because of the problem above, so these tests were changed not to check stride counts for input iterators. - Some tests were default constructing cpp17_input_iterator when a simple alternative was available -- those have been changed to use that alternative. Differential Revision: https://reviews.llvm.org/D115806
Loading
Please sign in to comment