Stratax 0.4.0rc1
Loading...
Searching...
No Matches
ReductionTraits.hpp
Go to the documentation of this file.
1
4#pragma once
5
6#include <type_traits>
7
16template<typename T>
18{
20 using sum_type = T;
22 using prod_type = T;
23};
24
31template<typename T>
34
41template<typename T>
43 typename ReductionTraits<std::remove_cvref_t<T>>::prod_type;
typename ReductionTraits< std::remove_cvref_t< T > >::prod_type reduction_prod_t
Accumulator and result type used by reduction::prod.
typename ReductionTraits< std::remove_cvref_t< T > >::sum_type reduction_sum_t
Accumulator and result type used by reduction::sum.
Selects accumulator and result types for numeric reductions.
T prod_type
Product accumulator and result type; not automatically widened.
T sum_type
Sum accumulator and result type; not automatically widened.