Explicit hashCode and equals for java.lang.runtime.SwitchBootstraps$TypePairs

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Fixed
    • Priority: P4
    • 23
    • Affects Version/s: None
    • Component/s: core-libs
    • None
    • b20

      When bootstrapping a switch expression via SwitchBootstraps we unconditionally load and create a map of TypePairs.

      - This map construction means the hashCode and equals methods will be generated. Implementing them explicitly avoids this added early code gen when loading SwitchBootstraps.

      - The TypePairs map is not needed by some bootstraps; moving the static HashMap into TypePairs avoids loading TypePairs altogether in some cases.

            Assignee:
            Claes Redestad
            Reporter:
            Claes Redestad
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: