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

Avoid reading volatile fields twice in Locale.getDefault(Category)

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Fixed
    • P4
    • 17
    • None
    • core-libs
    • None

    Description

      Current implementation of Locale.getDefault(Locale.Category) will read the volatile field holding the default locale at least twice. This has a minor performance cost, and could be unsound.

      Attachments

        Issue Links

          Activity

            People

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

              Dates

                Created:
                Updated:
                Resolved: