RFR: 8279361: Error in documentation of third Stream.reduce method
Viktor Klang
duke at openjdk.org
Mon Oct 3 08:41:12 UTC 2022
On Fri, 30 Sep 2022 21:34:44 GMT, Stuart Marks <smarks at openjdk.org> wrote:
>> This JavaDoc change attempts to shine some light on the `combiner`-function as it relates to the third variant of `Stream.reduce` since it according to the bug submission in JBS can be confusing that the `combiner` is not mentioned in the code example in the documentation.
>
> Deleting the pseudocode might be the right way to go. To restate the meta-issue, a problem with pseudocode is that it's difficult to separate the accidental from the essential. With something that has as much essential complexity as parallel reduction, it seems like pseudocode introduces a lot of accidental complexity that can be confusing or misleading. So yeah, if pseudocode isn't helping, then get rid of it.
@stuart-marks I'm inclined to agree with you and I have updated this PR to remove the pseudo-code from all places I found it in./cc @PaulSandoz
-------------
PR: https://git.openjdk.org/jdk/pull/10469
More information about the core-libs-dev
mailing list