|
|
@ -145,7 +145,7 @@ func MapReduceChan(source <-chan interface{}, mapper MapperFunc, reducer Reducer
|
|
|
|
return mapReduceWithPanicChan(source, panicChan, mapper, reducer, opts...)
|
|
|
|
return mapReduceWithPanicChan(source, panicChan, mapper, reducer, opts...)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// MapReduceChan maps all elements from source, and reduce the output elements with given reducer.
|
|
|
|
// mapReduceWithPanicChan maps all elements from source, and reduce the output elements with given reducer.
|
|
|
|
func mapReduceWithPanicChan(source <-chan interface{}, panicChan *onceChan, mapper MapperFunc,
|
|
|
|
func mapReduceWithPanicChan(source <-chan interface{}, panicChan *onceChan, mapper MapperFunc,
|
|
|
|
reducer ReducerFunc, opts ...Option) (interface{}, error) {
|
|
|
|
reducer ReducerFunc, opts ...Option) (interface{}, error) {
|
|
|
|
options := buildOptions(opts...)
|
|
|
|
options := buildOptions(opts...)
|
|
|
|