Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6555017

ClassFormatError for inner classes message misleading

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Won't Fix
    • Icon: P4 P4
    • 10
    • 7
    • hotspot
    • generic
    • generic

      The ClassFormatError message is somehow misleading:
      Exception in thread "main" java.lang.ClassFormatError: Illegal class modifiers in class test: 0x209

      It looks like the modifiers of class "test" is 0x209. I think
      a better message would be:
      Illegal class modifiers in class test's InnerClasses: 0x209
      or
      Illegal class modifiers in class test's inner class Enter: 0x209

      It would have saved a lot of time and debugging the VM to discover it was really
      the inner class whose modifiers were wrong.

            Unassigned Unassigned
            coleenp Coleen Phillimore
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: