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

java.lang.classfile.Attributes class performs a lot of static initializations

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P4 P4
    • 23
    • None
    • core-libs
    • None

      java.lang.classfile.Attributes has a static field for each predefined AttributeMapper and an extra field PREDEFINED_ATTRIBUTES initialized with a set of the mappers.

      Exposing predefined mappers as static fields requires a lot of static initialization in one of the class involved in the JDK bootstrap.

      In this enhancement I propose to expose all the mappers in a form of static methods to allow lazy initialization.

            asotona Adam Sotona
            asotona Adam Sotona
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: