8087115: Due to a javac type inference issue, sjavac doesn't compile with 8u31
authoralundblad
Wed, 10 Jun 2015 11:18:10 +0200
changeset 31116 2c8162f88493
parent 31115 8d8e98052d5d
child 31117 adbe1040a135
8087115: Due to a javac type inference issue, sjavac doesn't compile with 8u31 Summary: Added explicit type arguments. Reviewed-by: jlahoda
langtools/src/jdk.compiler/share/classes/com/sun/tools/sjavac/Util.java
--- a/langtools/src/jdk.compiler/share/classes/com/sun/tools/sjavac/Util.java	Tue Jun 09 15:57:45 2015 +0200
+++ b/langtools/src/jdk.compiler/share/classes/com/sun/tools/sjavac/Util.java	Wed Jun 10 11:18:10 2015 +0200
@@ -228,6 +228,6 @@
 
     public static <I, T> Map<I, T> indexBy(Collection<? extends T> c,
                                            Function<? super T, ? extends I> indexFunction) {
-        return c.stream().collect(Collectors.toMap(indexFunction, o -> o));
+        return c.stream().collect(Collectors.<T, I, T>toMap(indexFunction, o -> o));
     }
 }