[libcxx-commits] [PATCH] D101922: [libcxx][iterator] adds `std::ranges::advance`

Christopher Di Bella via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Thu May 6 10:11:45 PDT 2021


cjdb updated this revision to Diff 343446.
cjdb marked 4 inline comments as done.
cjdb added a comment.

responds to comments from @Mordante

- renames `__functionish` to `__function_like`
- adds synopsis
- changes `__abs` to return an unsigned
- adds `_LIBCPP_UNREACHABLE()`
- removes `_LIBCPP_DEBUG_LEVEL`

responds to comments from @Quuxplusone

- moves `__iterator/function_like.h` to `__function_like.h`
- SFINAEs out `std::advance` when `_Distance` isn't convertible to an integral
  - fixes expected error in verification test
- adds missing `_LIBCPP_POP_MACROS`

miscellaneous fixes:

- moves certain verification tests into `test_standard_function.h` so they can be put in `advance.pass.cpp`


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D101922

Files:
  libcxx/include/CMakeLists.txt
  libcxx/include/__function_like.h
  libcxx/include/__iterator/primitives.h
  libcxx/include/iterator
  libcxx/test/std/iterators/iterator.primitives/range.iter.ops/range.iter.ops.advance/advance.pass.cpp
  libcxx/test/std/iterators/iterator.primitives/range.iter.ops/range.iter.ops.advance/advance.verify.cpp
  libcxx/test/support/test_iterators.h
  libcxx/test/support/test_standard_function.h

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D101922.343446.patch
Type: text/x-patch
Size: 31896 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20210506/8b09b3d5/attachment-0001.bin>


More information about the libcxx-commits mailing list