Skip to content
Browse files
8193031: Collections.addAll is likely to perform worse than Collectio…

Reviewed-by: plevart
  • Loading branch information
stsypanov authored and Peter Levart committed Jan 15, 2021
1 parent 5855d52 commit 27a39c8d3f662c566fa877d191436500e579182f
Showing 1 changed file with 2 additions and 3 deletions.
@@ -5562,9 +5562,8 @@ public static boolean disjoint(Collection<?> c1, Collection<?> c2) {
* Adds all of the specified elements to the specified collection.
* Elements to be added may be specified individually or as an array.
* The behavior of this convenience method is identical to that of
* {@code c.addAll(Arrays.asList(elements))}, but this method is likely
* to run significantly faster under most implementations.
* The behaviour of this convenience method is similar to that of
* {@code cc.addAll(Collections.unmodifiableList(Arrays.asList(elements)))}.
* <p>When elements are specified individually, this method provides a
* convenient way to add a few elements to an existing collection:

1 comment on commit 27a39c8

Copy link

@openjdk-notifier openjdk-notifier bot commented on 27a39c8 Jan 15, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.