Typo in documentation of package java.util.stream

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P4
    • 9
    • Affects Version/s: 8
    • Component/s: core-libs
    • b22
    • generic
    • generic
    • Verified

      A DESCRIPTION OF THE PROBLEM :
      There is a typo at the end of this section of the package overview (right parenthesis instead of comma).

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
           int sumOfWeights = widgets.stream()
                                     .reduce(0,
                                             (sum, b) -> sum + b.getWeight(),
                                             Integer::sum);
       
      ACTUAL -
           int sumOfWeights = widgets.stream()
                                     .reduce(0,
                                             (sum, b) -> sum + b.getWeight())
                                             Integer::sum);
       

      URL OF FAULTY DOCUMENTATION :
      http://docs.oracle.com/javase/8/docs/api/java/util/stream/package-summary.html#Reduction

            Assignee:
            Paul Sandoz
            Reporter:
            Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: