Mercurial > hg > truffle
diff agent/src/share/classes/sun/jvm/hotspot/tools/jcore/ClassWriter.java @ 1913:3b2dea75431e
6984311: JSR 292 needs optional bootstrap method parameters
Summary: Allow CONSTANT_InvokeDynamic nodes to have any number of extra operands.
Reviewed-by: twisti
author | jrose |
---|---|
date | Sat, 30 Oct 2010 13:08:23 -0700 |
parents | 083fde3b838e |
children | f42a2f0c16bb |
line wrap: on
line diff
--- a/agent/src/share/classes/sun/jvm/hotspot/tools/jcore/ClassWriter.java Sat Oct 30 12:19:07 2010 -0700 +++ b/agent/src/share/classes/sun/jvm/hotspot/tools/jcore/ClassWriter.java Sat Oct 30 13:08:23 2010 -0700 @@ -323,10 +323,11 @@ case JVM_CONSTANT_InvokeDynamic: { dos.writeByte(cpConstType); - int value = cpool.getIntAt(ci); - short refIndex = (short) value; - dos.writeShort(refIndex); - if (DEBUG) debugMessage("CP[" + ci + "] = MT index = " + refIndex); + int[] values = cpool.getMultiOperandsAt(ci); + for (int vn = 0; vn < values.length; vn++) { + dos.writeShort(values[vn]); + } + if (DEBUG) debugMessage("CP[" + ci + "] = INDY indexes = " + Arrays.toString(values)); break; }