[libcxx-commits] [PATCH] D106507: [libcxx][ranges] Add ranges::take_view.

Arthur O'Dwyer via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Tue Jul 27 12:44:32 PDT 2021


Quuxplusone added inline comments.


================
Comment at: libcxx/test/support/test_iterators.h:701
 
-  cpp20_input_iterator() = default;
+  cpp20_input_iterator() = delete;
 
----------------
zoecarver wrote:
> cjdb wrote:
> > Why is this being deleted?
> These archetypes are meant to represent the minimum requirements of an iterator. C++20 input iterators are not required to be default constructible, therefore our C++20 input iterator archetype should not be default constructible. 
@zoecarver: FWIW, your archetype philosophy makes sense to me; but I wish this change to massively shared test code were done in a separate patch, not bundled in with this `counted_iterator` feature. (IIUC, all our existing tests are completely apathetic to this change: this change is neither required, nor harmful, to any existing test.)


================
Comment at: libcxx/test/support/test_range.h:58
-// clang-format on
-
 #endif // LIBCXX_TEST_SUPPORT_TEST_RANGE_H
----------------
woot! :) but also, please land this as a separate NFC commit (and you can just go ahead and do that).
Bonus points if you clean up the `> >` on lines 26, 35, 42, 51, and the spelling mistake on line 17, while you're at it.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D106507/new/

https://reviews.llvm.org/D106507



More information about the libcxx-commits mailing list