DataArrays.jl
DataArrays.jl copied to clipboard
Fix mapreduce() in a corner case
mapreduce_seq_impl() does not exist in Base for a long time (https://github.com/JuliaLang/julia/pull/16217), but this went unnoticed because since that code path is only used in very special conditions.
Another consequence of this bug is that the return type of mapreduce_pairwise_impl_skipna() was inferred as Any.
Add a test which would have triggered the failure.
Also rename a variable to fix a type instability due to using it for two different things.