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

additional clarifications to reversed() default methods' implementation requirements

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P4
    • 22
    • None
    • core-libs
    • None

    Description

      The changes to the implementation requirements for the reversed() methods of Deque, List, SortedMap, and SortedSet contain some wording that appears to be a testable assertion. For example, the Deque.reversed() implementation requirements state:

          The exact relationship between calls on the view and calls on this
          Deque is unspecified. However, order-sensitive operations generally
          delegate to the appropriate method with the opposite orientation. For
          example, calling {@code getFirst} on the view results in a call to
          {@code getLast} on this Deque.

      (List, SortedMap, and SortedSet contain similar wording, with changes corresponding to the interface name.)

      The intent was not that this be a testable assertion, but rather that this serve as an example of the kinds of behavior that clients of the interfaces can expect.

      Attachments

        Issue Links

          Activity

            People

              smarks Stuart Marks
              smarks Stuart Marks
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: