Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v14]

2023-08-09 Thread Pavel Rappo
On Tue, 8 Aug 2023 16:17:44 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v14]

2023-08-08 Thread Valerie Peng
On Tue, 8 Aug 2023 16:17:44 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v14]

2023-08-08 Thread Roger Riggs
On Tue, 8 Aug 2023 16:17:44 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v14]

2023-08-08 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-08 Thread Pavel Rappo
On Tue, 8 Aug 2023 11:54:42 GMT, Pavel Rappo wrote: >> src/java.security.jgss/share/classes/sun/security/krb5/internal/HostAddress.java >> line 105: >> >>> 103: return false; >>> 104: if (address != null && h.address != null) { >>> 105: return Arrays.equals(addre

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v13]

2023-08-08 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-08 Thread Pavel Rappo
On Fri, 4 Aug 2023 21:30:00 GMT, Valerie Peng wrote: >> Pavel Rappo has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Feedback > > src/java.security.jgss/share/classes/sun/security/krb5/internal/HostAddress.java > line 105: > >> 103:

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-07 Thread Valerie Peng
On Fri, 4 Aug 2023 22:00:41 GMT, Pavel Rappo wrote: >> src/java.security.jgss/share/classes/sun/security/krb5/internal/KRBError.java >> line 523: >> >>> 521: if (crealm != null) result = 37 * result + crealm.hashCode(); >>> 522: if (cname != null) result = 37 * result + cname.ha

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-07 Thread Valerie Peng
On Fri, 4 Aug 2023 15:11:47 GMT, Pavel Rappo wrote: >> src/java.base/share/classes/sun/security/provider/certpath/CertId.java line >> 182: >> >>> 180: myhash += Arrays.hashCode(issuerNameHash); >>> 181: myhash += Arrays.hashCode(issuerKeyHash); >>> 182: myhas

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Pavel Rappo
On Fri, 4 Aug 2023 21:40:37 GMT, Valerie Peng wrote: > Why changing the ordering? The order was changed to be parallel with that of `equals`. > I was wondering if you'd change this to Objects.hash(...) with all the fields > as arguments. Sure, we could use a convenience method, but because `e

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Valerie Peng
On Tue, 1 Aug 2023 08:57:56 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Valerie Peng
On Tue, 1 Aug 2023 08:57:56 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Pavel Rappo
On Fri, 4 Aug 2023 19:54:58 GMT, Sean Mullan wrote: > I would add to that list that I think it is really important any change to > the `hashCode` impl doesn't break the equals/hashCode contract, so it's > important to look at the `equals` implementation in conjunction with any > changes to `ha

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Pavel Rappo
On Fri, 4 Aug 2023 19:45:34 GMT, Sean Mullan wrote: >> Pavel Rappo has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Feedback > > src/java.base/share/classes/com/sun/crypto/provider/DESKey.java line 113: > >> 111: public int hashCode(

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Sean Mullan
On Fri, 4 Aug 2023 15:01:51 GMT, Pavel Rappo wrote: >> src/java.base/share/classes/sun/security/x509/PolicyInformation.java line >> 140: >> >>> 138: @Override >>> 139: public int hashCode() { >>> 140: return Objects.hash(policyIdentifier, policyQualifiers); >> >> What is the cr

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Sean Mullan
On Tue, 1 Aug 2023 08:57:56 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Pavel Rappo
On Fri, 4 Aug 2023 00:04:03 GMT, Valerie Peng wrote: >> Pavel Rappo has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Feedback > > src/java.base/share/classes/sun/security/provider/certpath/CertId.java line > 182: > >> 180: m

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Pavel Rappo
On Thu, 3 Aug 2023 21:43:44 GMT, Valerie Peng wrote: >> Pavel Rappo has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Feedback > > src/java.base/share/classes/sun/security/x509/PolicyInformation.java line 140: > >> 138: @Override >> 1

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Pavel Rappo
On Fri, 4 Aug 2023 09:35:54 GMT, Pavel Rappo wrote: >> src/java.base/share/classes/com/sun/crypto/provider/PBKDF2KeyImpl.java line >> 272: >> >>> 270: } >>> 271: >>> 272: if >>> (!(that.getAlgorithm().equalsIgnoreCase(getAlgorithm({ >> >> why removing the space be

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-04 Thread Pavel Rappo
On Thu, 3 Aug 2023 22:49:46 GMT, Valerie Peng wrote: >> Pavel Rappo has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Feedback > > src/java.base/share/classes/com/sun/crypto/provider/PBKDF2KeyImpl.java line > 272: > >> 270: }

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-03 Thread Valerie Peng
On Tue, 1 Aug 2023 08:57:56 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-03 Thread Valerie Peng
On Tue, 1 Aug 2023 08:57:56 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-03 Thread Valerie Peng
On Tue, 1 Aug 2023 08:57:56 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v12]

2023-08-01 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v11]

2023-07-31 Thread Sean Mullan
On Fri, 28 Jul 2023 22:14:09 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so bel

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v11]

2023-07-28 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v10]

2023-07-28 Thread Sean Mullan
On Mon, 17 Jul 2023 23:03:45 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so bel

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v9]

2023-07-17 Thread Pavel Rappo
On Mon, 17 Jul 2023 18:39:37 GMT, Daniel Jeliński wrote: > I think `oid.hashCode() + Arrays.hashCode(nameValue)` would have been good > enough, but deepHashCode is also acceptable. Fixed as you suggested, in 3139043370f. - PR Review Comment: https://git.openjdk.org/jdk/pull/14738#

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v10]

2023-07-17 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v9]

2023-07-17 Thread Daniel Jeliński
On Mon, 17 Jul 2023 18:13:38 GMT, Pavel Rappo wrote: >> Thanks for noticing this difference! >> >> Yes, the initial value would've been exponentiated (^ or ** in your >> notation). However, I note that the original code computed this: >> >> if nameValue.length > 0 >> >> (37^nameValue.leng

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v9]

2023-07-17 Thread Pavel Rappo
On Mon, 17 Jul 2023 12:23:17 GMT, Pavel Rappo wrote: >> The original code calculated `(37 ** >> nameValue.length)*(37+oid.hashCode)+Arrays.hashCode`; since you already >> dropped the multiplication, you can also drop the addition. > > Thanks for noticing this difference! > > Yes, the initial v

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v9]

2023-07-17 Thread Pavel Rappo
On Mon, 17 Jul 2023 11:02:46 GMT, Daniel Jeliński wrote: >> You think it was a typo (+ instead of *) in the original code? > > The original code calculated `(37 ** > nameValue.length)*(37+oid.hashCode)+Arrays.hashCode`; since you already > dropped the multiplication, you can also drop the addit

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v9]

2023-07-17 Thread Daniel Jeliński
On Mon, 17 Jul 2023 10:59:42 GMT, Pavel Rappo wrote: >> src/java.base/share/classes/sun/security/x509/OtherName.java line 212: >> >>> 210: public int hashCode() { >>> 211: if (myhash == -1) { >>> 212: myhash = 37 + oid.hashCode() + Arrays.hashCode(nameValue); >> >> I thi

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v9]

2023-07-17 Thread Daniel Jeliński
On Thu, 13 Jul 2023 22:57:49 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so bel

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v9]

2023-07-17 Thread Pavel Rappo
On Mon, 17 Jul 2023 10:15:18 GMT, Daniel Jeliński wrote: >> Pavel Rappo has updated the pull request incrementally with five additional >> commits since the last revision: >> >> - Feedback: avoid intermediate assignments >> - More previously missed cases >> - Fix: log hashCode as an unsigned

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v9]

2023-07-14 Thread Roger Riggs
On Thu, 13 Jul 2023 22:57:49 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so bel

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v8]

2023-07-13 Thread Pavel Rappo
On Thu, 13 Jul 2023 08:51:23 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so bel

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v9]

2023-07-13 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v8]

2023-07-13 Thread Roger Riggs
On Thu, 13 Jul 2023 08:51:23 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so bel

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v7]

2023-07-13 Thread Pavel Rappo
On Fri, 7 Jul 2023 23:19:27 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v8]

2023-07-13 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v7]

2023-07-11 Thread Pavel Rappo
On Fri, 7 Jul 2023 23:19:27 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v6]

2023-07-11 Thread Pavel Rappo
On Fri, 7 Jul 2023 19:21:29 GMT, Pavel Rappo wrote: > > Took another pass at this, looks good, but I would like to take another > > last look and make sure that changing the hash code for some of the classes > > like X509CRL is a benign change. > > Thanks, Sean. Take your time, you're an exper

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v7]

2023-07-07 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v6]

2023-07-07 Thread Pavel Rappo
On Fri, 7 Jul 2023 19:19:03 GMT, Sean Mullan wrote: > Took another pass at this, looks good, but I would like to take another last > look and make sure that changing the hash code for some of the classes like > X509CRL is a benign change. Thanks, Sean. Take your time, you're an expert in this

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v6]

2023-07-07 Thread Sean Mullan
On Thu, 6 Jul 2023 19:10:14 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v6]

2023-07-07 Thread Roger Riggs
On Thu, 6 Jul 2023 19:10:14 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v6]

2023-07-06 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v5]

2023-07-06 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-06 Thread Pavel Rappo
On Thu, 6 Jul 2023 17:06:31 GMT, Sean Mullan wrote: >> src/java.base/share/classes/sun/security/x509/X500Name.java line 422: >> >>> 420: // quick check that number of RDNs and AVAs match before >>> canonicalizing >>> 421: if (!Arrays.equals(this.names, other.names, >>> 422:

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-06 Thread Sean Mullan
On Thu, 6 Jul 2023 16:55:12 GMT, Jonathan Gibbons wrote: >> src/java.base/share/classes/java/security/cert/CertPath.java line 191: >> >>> 189: >>> 190: /** >>> 191: * {@return the hashcode value for this certification path} The >>> hash code >> >> This looks a bit odd w/o a period at

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-06 Thread Sean Mullan
On Wed, 5 Jul 2023 17:53:55 GMT, Roger Riggs wrote: >> Pavel Rappo has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains six additional >> commits sin

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-06 Thread Sean Mullan
On Wed, 5 Jul 2023 18:18:02 GMT, Roger Riggs wrote: >> Pavel Rappo has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains six additional >> commits sin

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-06 Thread Jonathan Gibbons
On Thu, 6 Jul 2023 16:41:37 GMT, Sean Mullan wrote: >> Pavel Rappo has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains six additional >> commits sin

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-06 Thread Sean Mullan
On Wed, 5 Jul 2023 14:52:22 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-06 Thread Pavel Rappo
On Thu, 6 Jul 2023 16:25:05 GMT, Sean Mullan wrote: >> Pavel Rappo has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains six additional >> commits sin

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-06 Thread Sean Mullan
On Wed, 5 Jul 2023 14:52:22 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-05 Thread Roger Riggs
On Wed, 5 Jul 2023 20:52:56 GMT, Pavel Rappo wrote: >> Are you sure? I just checked lines 91-92 and I'd say the change looks >> correct. > >> The original `<=` was correct, the number of bits in the input array must be >> less than the requested length of the BitArray. The constructors also >>

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-05 Thread Pavel Rappo
On Wed, 5 Jul 2023 19:35:23 GMT, Daniel Jeliński wrote: >> src/java.base/share/classes/sun/security/util/BitArray.java line 72: >> >>> 70: * specified byte array. The most significant bit of {@code a[0]} >>> gets >>> 71: * index zero in the BitArray. The array must be large enough to

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-05 Thread Pavel Rappo
On Wed, 5 Jul 2023 18:04:01 GMT, Roger Riggs wrote: >> Pavel Rappo has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains six additional >> commits sin

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-05 Thread Daniel Jeliński
On Wed, 5 Jul 2023 18:11:41 GMT, Roger Riggs wrote: >> Pavel Rappo has updated the pull request with a new target base due to a >> merge or a rebase. The incremental webrev excludes the unrelated changes >> brought in by the merge/rebase. The pull request contains six additional >> commits sin

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-05 Thread Roger Riggs
On Wed, 5 Jul 2023 14:52:22 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-05 Thread Daniel Jeliński
On Wed, 5 Jul 2023 14:52:22 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v3]

2023-07-05 Thread Pavel Rappo
On Wed, 5 Jul 2023 12:16:32 GMT, Daniel Jeliński wrote: >> Pavel Rappo has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Add even more cases and tidy up > > src/java.base/share/classes/sun/security/provider/PolicyParser.java line 1133: >

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v4]

2023-07-05 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v3]

2023-07-05 Thread Pavel Rappo
On Wed, 5 Jul 2023 14:39:44 GMT, Pavel Rappo wrote: >> src/java.base/share/classes/java/security/spec/ECFieldF2m.java line 235: >> >>> 233: public int hashCode() { >>> 234: int value = m << 5; >>> 235: // consider simplifying using Objects.hashCode(rp) after >>> JDK-8015417

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v3]

2023-07-05 Thread Pavel Rappo
On Wed, 5 Jul 2023 12:31:09 GMT, Daniel Jeliński wrote: >> Pavel Rappo has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Add even more cases and tidy up > > src/java.base/share/classes/java/security/spec/ECFieldF2m.java line 235: > >> 233

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v3]

2023-07-05 Thread Daniel Jeliński
On Tue, 4 Jul 2023 16:27:05 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v3]

2023-07-05 Thread Daniel Jeliński
On Tue, 4 Jul 2023 16:27:05 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v3]

2023-07-05 Thread Daniel Jeliński
On Tue, 4 Jul 2023 16:27:05 GMT, Pavel Rappo wrote: >> Please review this PR to use modern APIs and language features to simplify >> `equals` and `hashCode` in security area. >> >> I understand that security area is sensitive and a non-expert, such as >> myself, should tread carefully; so belo

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v3]

2023-07-04 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

Re: RFR: 8311170: Simplify and modernize equals and hashCode in security area [v2]

2023-06-30 Thread Pavel Rappo
> Please review this PR to use modern APIs and language features to simplify > `equals` and `hashCode` in security area. > > I understand that security area is sensitive and a non-expert, such as > myself, should tread carefully; so below are my notes to assist the review. > > * Unlike `hashCod

RFR: 8311170: Simplify and modernize equals and hashCode in security area

2023-06-30 Thread Pavel Rappo
Please review this PR to use modern APIs and language features to simplify `equals` and `hashCode` in security area. I understand that security area is sensitive and a non-expert, such as myself, should tread carefully; so below are my notes to assist the review. * Unlike `hashCode`, non-secure