Skip to content

Commit

Permalink
[libc++][NFC] Fix copy-paste error in the transform_view tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ldionne committed Jul 30, 2021
1 parent 532d05b commit 7b3ada7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,14 @@
#include "test_iterators.h"
#include "types.h"

template<class T, class F>
concept ValidTransformView = requires { typename std::ranges::transform_view<T, F>; };

struct BadFunction { };
static_assert( ValidTransformView<ContiguousView, Increment>);
static_assert(!ValidTransformView<Range, Increment>);
static_assert(!ValidTransformView<ContiguousView, BadFunction>);

template<std::ranges::range R>
auto toUpper(R range) {
return std::ranges::transform_view(range, [](char c) { return std::toupper(c); });
Expand Down
3 changes: 0 additions & 3 deletions libcxx/test/std/ranges/range.adaptors/range.transform/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,6 @@

int globalBuff[8] = {0,1,2,3,4,5,6,7};

template<class T, class F>
concept ValidDropView = requires { typename std::ranges::transform_view<T, F>; };

struct ContiguousView : std::ranges::view_base {
int start_;
int *ptr_;
Expand Down

0 comments on commit 7b3ada7

Please sign in to comment.