Skip to content

Commit

Permalink
DPL Analysis: mark a few functions consteval
Browse files Browse the repository at this point in the history
  • Loading branch information
ktf committed Jun 29, 2024
1 parent 8519660 commit 8fd0c2d
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions Framework/Core/include/Framework/ASoA.h
Original file line number Diff line number Diff line change
Expand Up @@ -1081,25 +1081,25 @@ static constexpr std::string getLabelFromTypeForKey(std::string const& key)
}

template <typename B, typename... C>
constexpr static bool hasIndexTo(framework::pack<C...>&&)
consteval static bool hasIndexTo(framework::pack<C...>&&)
{
return (o2::soa::is_binding_compatible_v<B, typename C::binding_t>() || ...);
}

template <typename B, typename... C>
constexpr static bool hasSortedIndexTo(framework::pack<C...>&&)
consteval static bool hasSortedIndexTo(framework::pack<C...>&&)
{
return ((C::sorted && o2::soa::is_binding_compatible_v<B, typename C::binding_t>()) || ...);
}

template <typename B, typename Z>
constexpr static bool relatedByIndex()
consteval static bool relatedByIndex()
{
return hasIndexTo<B>(typename Z::table_t::external_index_columns_t{});
}

template <typename B, typename Z>
constexpr static bool relatedBySortedIndex()
consteval static bool relatedBySortedIndex()
{
return hasSortedIndexTo<B>(typename Z::table_t::external_index_columns_t{});
}
Expand Down Expand Up @@ -1187,7 +1187,7 @@ template <typename T>
inline constexpr bool is_soa_iterator_v = framework::is_base_of_template_v<RowViewCore, T> || framework::is_specialization_v<T, RowViewCore>;

template <typename T>
inline constexpr bool is_soa_filtered_iterator_v()
inline consteval bool is_soa_filtered_iterator_v()
{
if constexpr (!is_soa_iterator_v<T>) {
return false;
Expand Down Expand Up @@ -1216,7 +1216,7 @@ inline constexpr bool is_soa_filtered_v = framework::is_base_of_template_v<soa::

/// Helper function to extract bound indices
template <typename... Is>
static constexpr auto extractBindings(framework::pack<Is...>)
static consteval auto extractBindings(framework::pack<Is...>)
{
return framework::pack<typename Is::binding_t...>{};
}
Expand Down

0 comments on commit 8fd0c2d

Please sign in to comment.