On Wed, May 10, 2017 at 10:49 AM, Gilles <[email protected]> wrote:
> Hi. > > > On Tue, 9 May 2017 12:59:40 -0400, Raymond DeCampo wrote: > >> If I make the method static and rename it to "gamma", then I can do the >>> >> much >> >>> simpler: >>> Stream<Double> d = numbers.parallelStream().map(Gamma::gamma); >>> >> >> It seems to me like the above, suggested by Stian earlier if I am not >> mistaken, is the best option of the ones you have discussed, once you >> agree >> on a name for the static method. >> >> I don't think there is a need to explicitly implement DoubleUnaryOperator >> as a method reference can always be implicitly converter by the compiler. >> > > Is commit ef4ab32365ea7f5a0debb9f48734839b5ed00a86 OK (as far as usage > with Java 8 is concerned)? > > If we decide to have "Numbers" target Java 8, we'll define an additional > (non-static) "apply(double)" method that will call the static one. > > Regards, > Gilles Looks good to me.
