+str - improves type inference on by separating the seed from the op (currying)

This commit is contained in:
Viktor Klang 2014-11-03 20:49:55 +01:00
parent 59a3d0c450
commit 82095da708
4 changed files with 7 additions and 7 deletions

View file

@ -357,7 +357,7 @@ class Source[+Out](delegate: scaladsl.Source[Out]) {
* @param aggregate Takes the currently aggregated value and the current pending element to produce a new aggregate
*/
def conflate[S](seed: japi.Function[Out, S], aggregate: japi.Function2[S, Out, S]): javadsl.Source[S] =
new Source(delegate.conflate(seed.apply, aggregate.apply))
new Source(delegate.conflate(seed.apply)(aggregate.apply))
/**
* Allows a faster downstream to progress independently of a slower publisher by extrapolating elements from an older