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

Add java.util.Objects.newIdentity method

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Fixed
    • Icon: P3 P3
    • repo-valhalla
    • None
    • core-libs
    • None

      Replace the java.util.Objects.newIdentity() method with the version slated for JDK 17
      and remove the previous placeholder.

      /**
       * {@return a new instance of an unspecified class}
       * The object has a unique identity; no other references to it exist.
       * It can be used for synchronization, or where a placeholder Object is needed.
       * Use this method to avoid relying on the {@linkplain Object#Object() Object constructor}.
       *
       * @since 17
       */
      public static Object newIdentity() {...}

            rriggs Roger Riggs
            rriggs Roger Riggs
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: