[libcxx-commits] [PATCH] D106205: [libcxx][ranges] Add `counted_iterator`.

Christopher Di Bella via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon Jul 26 18:58:03 PDT 2021


cjdb accepted this revision.
cjdb added a comment.

I'd like for some of the simple-ish noexcept specifiers to return, but LGTM.



================
Comment at: libcxx/include/__iterator/counted_iterator.h:107
+  _LIBCPP_HIDE_FROM_ABI
+  constexpr iter_difference_t<_Iter> count() const noexcept { return __count_; }
+
----------------
ldionne wrote:
> Are you testing the `noexcept`-ness of this method in your tests? If not, you should, especially since it's in the spec.
Why did the noexcept specifier removed? It's not a difficult one to get right and is arguably useful.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D106205



More information about the libcxx-commits mailing list