[libcxx-commits] [PATCH] D115116: [libc++] Work around a Clang bug in transform_view, and regression-test.

Arthur O'Dwyer via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Mon Dec 6 08:19:26 PST 2021


Quuxplusone added a comment.

Yep, or rather, my goal was to get my local Clang+libc++ to compile some training-lab-exercise code like

  bool isPalindromicByAuthor(std::ranges::bidirectional_range auto&& r) {
      return std::ranges::equal(
          r | std::views::transform(&Book::author),
          r | std::views::reverse | std::views::transform(&Book::author)
      );
  }
  ~~~
  assert(isPalindromicByAuthor(shelf | std::views::drop(1)));

This bug and `take/drop` were basically leaves of the same tree.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D115116



More information about the libcxx-commits mailing list