-
Enhancement
-
Resolution: Fixed
-
P3
-
7u51, 8u20
-
b124
-
Not verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8159859 | 9 | Jonathan Gibbons | P3 | Resolved | Fixed | team |
javap outputs MethodHandle constants as follows:
#24 = MethodHandle #9:#33 // invokeinterface InterfaceMethodref$I.m:()V
As is typical, "#33" is a cross-reference to constant pool entry 33, which in this case is an InterfaceMethodref.
But "#9" has nothing to do with constant pool entry 9, or any other indexed list: it's simply an enum-style value, representing the reference_kind "invokeinterface" (see JVMS 5.4.3.5).
It might be cleaner to drop the '#', or use some other (non-numeric?) representation.
#24 = MethodHandle #9:#33 // invokeinterface InterfaceMethodref$I.m:()V
As is typical, "#33" is a cross-reference to constant pool entry 33, which in this case is an InterfaceMethodref.
But "#9" has nothing to do with constant pool entry 9, or any other indexed list: it's simply an enum-style value, representing the reference_kind "invokeinterface" (see JVMS 5.4.3.5).
It might be cleaner to drop the '#', or use some other (non-numeric?) representation.
- backported by
-
JDK-8159859 Use of '#' to represent MethodHandle kind is confusing
-
- Resolved
-