Skip to content

Commit

Permalink
Simplify code
Browse files Browse the repository at this point in the history
  • Loading branch information
d-frey committed Nov 23, 2024
1 parent edfa28d commit cc47529
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion include/tao/pq/bind.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

namespace tao::pq
{
template< typename, typename = void >
template< typename >
struct bind;

} // namespace tao::pq
Expand Down
5 changes: 3 additions & 2 deletions include/tao/pq/internal/aggregate.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,12 @@ namespace tao::pq::internal
template< std::size_t >
using indexed_convert_to_any = convert_to_any;

template< typename, typename, typename = void >
template< typename, typename >
inline constexpr bool check_aggregate_args_impl = false;

template< typename T, std::size_t... Is >
inline constexpr bool check_aggregate_args_impl< T, std::index_sequence< Is... >, decltype( (void)T{ std::declval< indexed_convert_to_any< Is > >()... } ) > = true;
requires requires { T{ std::declval< indexed_convert_to_any< Is > >()... }; }
inline constexpr bool check_aggregate_args_impl< T, std::index_sequence< Is... > > = true;

template< typename T, std::size_t N >
inline constexpr bool check_aggregate_args = check_aggregate_args_impl< T, std::make_index_sequence< N > >;
Expand Down

0 comments on commit cc47529

Please sign in to comment.