Type-instability of mapreduce vs. map + reduce

The magic line is @eval Base mapreduce_empty(f, op, T) = _empty_reduce_error(). But probably not something you want to do in this context.

If you use a named function for the mapper, then you could overload this without piracy or shame.

2 Likes