Skip to content

Commit

Permalink
Correct element type tests for const 1D cartesian_products.
Browse files Browse the repository at this point in the history
Co-authored-by: Tristan Brindle <t.c.brindle@gmail.com>
  • Loading branch information
brycelelbach and tcbrindle committed Jul 31, 2023
1 parent fe8ff5d commit 42381ac
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions test/test_cartesian_product.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,9 @@ constexpr bool test_cartesian_product()
static_assert(std::same_as<flux::value_t<C>, std::tuple<int>>);
static_assert(std::same_as<flux::rvalue_element_t<C>, std::tuple<int&&>>);

// FIXME: These currently fail - they're actually `tuple<const int>` etc. Is that correct?
//static_assert(std::same_as<flux::element_t<C const>, std::tuple<int&>>);
//static_assert(std::same_as<flux::value_t<C const>, std::tuple<int>>);
//static_assert(std::same_as<flux::rvalue_element_t<C const>, std::tuple<int&&>>);
static_assert(std::same_as<flux::element_t<C const>, std::tuple<int const&>>);
static_assert(std::same_as<flux::value_t<C const>, std::tuple<int>>);
static_assert(std::same_as<flux::rvalue_element_t<C const>, std::tuple<int const&&>>);

STATIC_CHECK(flux::size(cart) == 3);

Expand Down

0 comments on commit 42381ac

Please sign in to comment.