langtools/src/jdk.compiler/share/classes/com/sun/tools/javac/comp/Resolve.java
changeset 41943 a4ee110842fb
parent 41932 b23b4712933b
child 42824 89b14017e8d6
equal deleted inserted replaced
41942:260c724e5614 41943:a4ee110842fb
   552             // This is not a polymorphic method, but typeargs are supplied
   552             // This is not a polymorphic method, but typeargs are supplied
   553             // which is fine, see JLS 15.12.2.1
   553             // which is fine, see JLS 15.12.2.1
   554         } else if (mt.hasTag(FORALL) && typeargtypes.nonEmpty()) {
   554         } else if (mt.hasTag(FORALL) && typeargtypes.nonEmpty()) {
   555             ForAll pmt = (ForAll) mt;
   555             ForAll pmt = (ForAll) mt;
   556             if (typeargtypes.length() != pmt.tvars.length())
   556             if (typeargtypes.length() != pmt.tvars.length())
   557                 throw inapplicableMethodException.setMessage("arg.length.mismatch"); // not enough args
   557                  // not enough args
       
   558                 throw inapplicableMethodException.setMessage("wrong.number.type.args", Integer.toString(pmt.tvars.length()));
   558             // Check type arguments are within bounds
   559             // Check type arguments are within bounds
   559             List<Type> formals = pmt.tvars;
   560             List<Type> formals = pmt.tvars;
   560             List<Type> actuals = typeargtypes;
   561             List<Type> actuals = typeargtypes;
   561             while (formals.nonEmpty() && actuals.nonEmpty()) {
   562             while (formals.nonEmpty() && actuals.nonEmpty()) {
   562                 List<Type> bounds = types.subst(types.getBounds((TypeVar)formals.head),
   563                 List<Type> bounds = types.subst(types.getBounds((TypeVar)formals.head),