JCMD's dependency on hardcoded Constant Pool indexes should be eliminated

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Duplicate
    • Priority: P3
    • tbd
    • Affects Version/s: 12
    • Component/s: hotspot
    • 11

      Hotspot file reflectionAccessorImplKlassHelper.cpp, used by jcmd to inspect reflection generated classes, uses hard-coded constant pool indices to find information in these classes. For example, for reflection generated classes that are not SerializationConstructorAccessors, it expects the method name and signature to be in constant pool indexes 7 and 8.

      This dependency on hard-coded constant pool indices is fragile and can easily be broken. The implementation of reflectionAccessorImplKlassHelper.cpp should be changed to something less fragile.

            Assignee:
            Thomas Stuefe
            Reporter:
            Harold Seigel (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: