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

Class.newInstance() versus inner classes

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 7
    • 1.4.0
    • specification
    • rc
    • generic
    • solaris_7
    • Verified

      JLS 13.4.11 (Method and Constructor Declarations) together with the documentation for Class.newInstance() imply that you can instatiate an inner class this way. But of course you can't, because of the additional parameter supplied by the compiler. This needs to be documented somewhere.

      [And if I hear one more time that this belongs in the "Java compiler specification" I'll just have to write one. So don't make me do it. ;-)]

      neal.gafter@Eng 2001-01-05

            abuckley Alex Buckley
            gafter Neal Gafter (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: