< prev index next >

src/java.base/share/classes/jdk/internal/nicl/UpcallHandler.java

Print this page

        

*** 83,93 **** if (!c.isInstance(o)) { throw new IllegalArgumentException("Object must implement FunctionalInterface class: " + c.getName()); } Method ficMethod = Util.findFunctionalInterfaceMethod(c); ! Function ftype = Util.functionof(ficMethod); MethodType mt = MethodHandles.publicLookup().unreflect(ficMethod).type().dropParameterTypes(0, 1); MethodHandle mh = MethodHandles.publicLookup().findVirtual(c, "fn", mt); --- 83,93 ---- if (!c.isInstance(o)) { throw new IllegalArgumentException("Object must implement FunctionalInterface class: " + c.getName()); } Method ficMethod = Util.findFunctionalInterfaceMethod(c); ! Function ftype = Util.functionof(c); MethodType mt = MethodHandles.publicLookup().unreflect(ficMethod).type().dropParameterTypes(0, 1); MethodHandle mh = MethodHandles.publicLookup().findVirtual(c, "fn", mt);
< prev index next >