This is an archive of the discontinued LLVM Phabricator instance.

[libc++] Remove cpp17_input_iterator.h
ClosedPublic

Authored by philnik on Feb 15 2022, 12:12 PM.

Details

Reviewers
Quuxplusone
ldionne
Group Reviewers
Restricted Project
Commits
rGf75f171b2050: [libc++] Remove cpp17_input_iterator.h

Diff Detail

Event Timeline

philnik requested review of this revision.Feb 15 2022, 12:12 PM
philnik created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptFeb 15 2022, 12:12 PM
Herald added a reviewer: Restricted Project. · View Herald Transcript

Seems plausible to me, but why on earth does this file exist? Shouldn't whoever-uses-it just be using test/support/test_iterators.h instead?
I notice that the header guard's name is incorrect too, and I assume that's simply an artifact of this file's getting accidentally caught up in the big input_iterator->cpp17_input_iterator rename circa last year.
Could you dig into whether we can just use test_iterators.h in the appropriate places and git rm this file?

philnik updated this revision to Diff 409022.Feb 15 2022, 12:54 PM
  • Remove cpp17_input_iterator.h
philnik retitled this revision from [libc++] Make cpp17_input_iterator constexpr to [libc++] Remove cpp17_input_iterator.h.Feb 15 2022, 12:54 PM
Quuxplusone accepted this revision.Feb 15 2022, 1:14 PM

Awesome, LGTM if CI is green.

Pre-existing issues that could be worth fixing in a followup PR if you're interested:

  • iter_alloc.pass.cpp should be named iter_iter.pass.cpp/iter_iter_alloc.pass.cpp.
  • It should test all the different test iterators, not just It=char* and It=cpp17_input_iterator<const char*>.
  • It should be refactored in the obvious way to test<It>() instead of test(It, It), to cut down on repetition.
This revision is now accepted and ready to land.Feb 15 2022, 1:14 PM
This revision was landed with ongoing or failed builds.Feb 15 2022, 7:18 PM
This revision was automatically updated to reflect the committed changes.