Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
Description
I have the following program
import java.util.List; import java.util.function.Predicate; class Main { static final <T> void test() { List<T> x = null; Predicate<? super T> y = x::add; } }
Actual behavior
org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed: Main.groovy: 9: Failed to find method 'add(T)' for the type: java.util.List<T> @ line 9, column 30. Predicate<? super T> y = x::add; ^ 1 error
Expected behavior
Compile successfully
Tested against master (commit: a29ce1ce64d565526b70e145ace665dd0617ec9b)