java.security.spec.EllipticCurve#hashCode javadoc inconsistent w/ implementation

XMLWordPrintable

      A DESCRIPTION OF THE PROBLEM :
      The documentation states the computation of EllipticCurve#hashCode() as
      (field.hashCode() << 6) + (a.hashCode() << 4) + (b.hashCode() << 2)
      whereas the implementation is
      (field.hashCode() << 6 + (a.hashCode() << 4) + (b.hashCode() << 2))
      Since operator + takes precedence over << the parentheses matter.
      PS: on top of that, the hash code function is atypical, since the lowest 2 bits are not equally distributed.


            Assignee:
            Anthony Scarpino
            Reporter:
            Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: