/* * @test /nodynamiccopyright/ * @bug 8144767 * @summary Correct most-specific test when wildcards appear in functional interface type * @compile/fail/ref=MostSpecific32.out -XDrawDiagnostics MostSpecific32.java */ class MostSpecific32 { interface A {} interface B extends A {} interface F1 { A apply(); } interface F2 { B apply(); } static void m1(F1 f1) {} static void m1(F2 f2) {} void test() { m1(() -> null); // B } }