Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-7904014

jasm: the jasm incorrectly parses the PermittedSubclasses/NestMembers attribute

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P2 P2
    • None
    • asm_tools_9.0
    • tools

      The JASM file:
      super public class javasoft/sqe/tests/vm/classfmt/atr/atrseal002/atrseal00206m002/X
              version 62:0
      {
        public Method "<init>":"()V"
              stack 1 locals 1
        {
                      aload_0;
                      invokespecial Method java/lang/Object."<init>":"()V";
                      return;
        }
        PermittedSubclasses javasoft/sqe/tests/vm/classfmt/atr/atrseal002/atrseal00206m002/atrseal00206m002;
      } // end Class X
      is converted to:

      package javasoft/sqe/tests/vm/classfmt/atr/atrseal002/atrseal00206m002;

      public super class #3 /* X */ version 62:0
      {
        const #1 = Method #9.#10; // java/lang/Object."<init>":"()V"
        const #2 = Utf8 "javasoft/sqe/tests/vm/classfmt/atr/atrseal002/atrseal00206m002/X";
        const #3 = class #2; // X
        const #4 = Utf8 "<init>";
        const #5 = Utf8 "()V";
        const #6 = Utf8 "Code";
        const #7 = Utf8 "LineNumberTable";
        const #8 = Utf8 "java/lang/Object";
        const #9 = class #8; // java/lang/Object
        const #10 = NameAndType #4:#5; // "<init>":"()V"
        const #11 = Utf8 "javasoft/sqe/tests/vm/classfmt/atr/atrseal002/atrseal00206m002/atrseal00206m002";
        const #12 = Utf8 "PermittedSubclasses";
        const #13 = Utf8 "X.jasm";
        const #14 = Utf8 "SourceFile";

        public Method #4:#5 // "<init>":"()V"
          stack 1 locals 1
        {
           0: aload_0;
           1: invokespecial #1; // Method java/lang/Object."<init>":"()V"
           4: return;
        }

        PermittedSubclasses #11; // "javasoft/sqe/tests/vm/classfmt/atr/atrseal002/atrseal00206m002/atrseal00206m002"
      However, the expected PermittedSubclasses should refer to a constant pool class entry instead of a Utf8.

            lkuskov Leonid Kuskov
            lkuskov Leonid Kuskov
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: