Skip to content

Commit

Permalink
fix: allow altMetafactory method in lambda call site (#1760)
Browse files Browse the repository at this point in the history
  • Loading branch information
skylot committed Jan 15, 2023
1 parent df38a64 commit 068e4b8
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,11 @@ public static boolean isLambdaInvoke(List<EncodedValue> values) {
return false;
}
IMethodRef methodRef = methodHandle.getMethodRef();
if (!methodRef.getName().equals("metafactory")) {
return false;
}
if (!methodRef.getParentClassType().equals("Ljava/lang/invoke/LambdaMetafactory;")) {
return false;
}
return true;
String mthName = methodRef.getName();
return mthName.equals("metafactory") || mthName.equals("altMetafactory");
}

public static InvokeCustomNode buildLambdaMethodCall(MethodNode mth, InsnData insn, boolean isRange, List<EncodedValue> values) {
Expand Down

0 comments on commit 068e4b8

Please sign in to comment.