8259816: Typo in java.util.stream package description

Reviewed-by: iris, lancea, naoto
This commit is contained in:
Stuart Marks 2021-01-27 19:02:49 +00:00
parent 0eed2c3312
commit eb9236853c

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2012, 2020, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2012, 2021, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -346,7 +346,7 @@
* <pre>{@code
* List<String> results =
* stream.filter(s -> pattern.matcher(s).matches())
* .collect(Collectors.toList()); // No side-effects!
* .toList(); // No side-effects!
* }</pre>
*
* <h3><a id="Ordering">Ordering</a></h3>
@ -436,7 +436,7 @@
* can operate on subsets of the data in parallel, and then combine the
* intermediate results to get the final correct answer. (Even if the language
* had a "parallel for-each" construct, the mutative accumulation approach would
* still required the developer to provide
* still require the developer to provide
* thread-safe updates to the shared accumulating variable {@code sum}, and
* the required synchronization would then likely eliminate any performance gain from
* parallelism.) Using {@code reduce()} instead removes all of the