--- a/langtools/src/share/classes/com/sun/tools/javac/comp/Check.java Sat Apr 17 08:12:45 2010 -0700
+++ b/langtools/src/share/classes/com/sun/tools/javac/comp/Check.java Wed Apr 21 12:24:56 2010 +0100
@@ -677,6 +677,19 @@
}
}
+ /**
+ * Check that vararg method call is sound
+ * @param pos Position to be used for error reporting.
+ * @param argtypes Actual arguments supplied to vararg method.
+ */
+ void checkVararg(DiagnosticPosition pos, List<Type> argtypes) {
+ Type argtype = argtypes.last();
+ if (!types.isReifiable(argtype))
+ warnUnchecked(pos,
+ "unchecked.generic.array.creation",
+ argtype);
+ }
+
/** Check that given modifiers are legal for given symbol and
* return modifiers together with any implicit modififiers for that symbol.
* Warning: we can't use flags() here since this method