Merge
authormullan
Tue, 25 Jan 2011 08:41:46 -0500
changeset 8155 03e638d615c0
parent 8154 cbb914db1110 (current diff)
parent 8151 88b01a6d5f51 (diff)
child 8156 601a0ec31a79
Merge
--- a/jdk/src/share/classes/java/util/Arrays.java	Mon Jan 24 15:46:05 2011 -0500
+++ b/jdk/src/share/classes/java/util/Arrays.java	Tue Jan 25 08:41:46 2011 -0500
@@ -2823,6 +2823,7 @@
      * @param a the array by which the list will be backed
      * @return a list view of the specified array
      */
+    @SafeVarargs
     public static <T> List<T> asList(T... a) {
         return new ArrayList<>(a);
     }
--- a/jdk/src/share/classes/java/util/Collections.java	Mon Jan 24 15:46:05 2011 -0500
+++ b/jdk/src/share/classes/java/util/Collections.java	Tue Jan 25 08:41:46 2011 -0500
@@ -3827,6 +3827,7 @@
      * @see Collection#addAll(Collection)
      * @since 1.5
      */
+    @SafeVarargs
     public static <T> boolean addAll(Collection<? super T> c, T... elements) {
         boolean result = false;
         for (T element : elements)
--- a/jdk/src/share/classes/java/util/EnumSet.java	Mon Jan 24 15:46:05 2011 -0500
+++ b/jdk/src/share/classes/java/util/EnumSet.java	Tue Jan 25 08:41:46 2011 -0500
@@ -317,6 +317,7 @@
      *     or if <tt>rest</tt> is null
      * @return an enum set initially containing the specified elements
      */
+    @SafeVarargs
     public static <E extends Enum<E>> EnumSet<E> of(E first, E... rest) {
         EnumSet<E> result = noneOf(first.getDeclaringClass());
         result.add(first);
--- a/jdk/src/share/classes/javax/swing/SwingWorker.java	Mon Jan 24 15:46:05 2011 -0500
+++ b/jdk/src/share/classes/javax/swing/SwingWorker.java	Tue Jan 25 08:41:46 2011 -0500
@@ -404,6 +404,7 @@
      * @see #process
      *
      */
+    @SafeVarargs
     protected final void publish(V... chunks) {
         synchronized (this) {
             if (doProcess == null) {
--- a/jdk/src/share/classes/sun/swing/AccumulativeRunnable.java	Mon Jan 24 15:46:05 2011 -0500
+++ b/jdk/src/share/classes/sun/swing/AccumulativeRunnable.java	Tue Jan 25 08:41:46 2011 -0500
@@ -120,6 +120,7 @@
      * {@code Runnable} for execution.
      * @param args the arguments to accumulate
      */
+    @SafeVarargs
     public final synchronized void add(T... args) {
         boolean isSubmitted = true;
         if (arguments == null) {