--- a/nashorn/src/jdk/internal/dynalink/beans/OverloadedDynamicMethod.java Tue Feb 25 18:56:10 2014 +0530
+++ b/nashorn/src/jdk/internal/dynalink/beans/OverloadedDynamicMethod.java Wed Feb 26 13:17:57 2014 +0100
@@ -148,7 +148,6 @@
}
}
- @SuppressWarnings("fallthrough")
@Override
public MethodHandle getInvocation(final CallSiteDescriptor callSiteDescriptor, final LinkerServices linkerServices) {
final MethodType callSiteType = callSiteDescriptor.getMethodType();
@@ -207,7 +206,7 @@
case 1: {
// Very lucky, we ended up with a single candidate method handle based on the call site signature; we
// can link it very simply by delegating to the SingleDynamicMethod.
- invokables.iterator().next().getInvocation(callSiteDescriptor, linkerServices);
+ return invokables.iterator().next().getInvocation(callSiteDescriptor, linkerServices);
}
default: {
// We have more than one candidate. We have no choice but to link to a method that resolves overloads on