The invokedynamic instruction requires a MethodHandle constant pool 
entry for a bootstrap method.

This MH CP entry can be one of 9 REF_xxx types.

Questions:

Q1. Which types are valid in the case of bootstrap method?

Q2. What happens if I try to use invalid types?

I could not find answers in the current specification.

I guess that the correct answers would be:

A1. The valid types are: REF_getStatic, REF_invokeStatic (? and maybe 
REF_newInvokeSpecial). All others are invalid for bootstraping.

A2. If the type is invalid, JVM throws an exception (and doesn't try to 
call bootstrap MH taking arguments from Java stack)

Thanks in advance!

Kirill






_______________________________________________
mlvm-dev mailing list
[email protected]
http://mail.openjdk.java.net/mailman/listinfo/mlvm-dev

Reply via email to