--- old/src/share/classes/com/sun/tools/javac/code/Type.java 2010-09-10 17:47:41.841814503 +0100 +++ new/src/share/classes/com/sun/tools/javac/code/Type.java 2010-09-10 17:47:41.754135422 +0100 @@ -1061,6 +1061,21 @@ return qtype.isErroneous(); } + /** + * Replaces this ForAll's typevars with a set of concrete Java types + * and returns the instantiated generic type. Subclasses might override + * in order to check that the list of types is a valid instantiation + * of the ForAll's typevars. + * + * @param actuals list of actual types + * @param types types instance + * @return qtype where all occurrences of tvars are replaced + * by types in actuals + */ + public Type inst(List actuals, Types types) { + return types.subst(qtype, tvars, actuals); + } + public Type map(Mapping f) { return f.apply(qtype); }