Skip to content

Commit 51285c1

Browse files
authored
Fix CPU implementation of Reduce::MinMax(n, ptr) (#5322)
There was a stray template parameter.
1 parent bb0a1f3 commit 51285c1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Src/Base/AMReX_Reduce.H

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1492,7 +1492,7 @@ std::pair<T,T> MinMax (N n, F const& f)
14921492
return std::make_pair(r_min,r_max);
14931493
}
14941494

1495-
template <typename T, typename N, typename M>
1495+
template <typename T, typename N, std::enable_if_t<std::is_integral_v<N>,int>>
14961496
std::pair<T,T> MinMax (N n, T const* v)
14971497
{
14981498
return Reduce::MinMax<T>(n, [=] (N i) -> T { return v[i]; });

0 commit comments

Comments
 (0)