On Mon, 16 Sep 2024 17:06:26 GMT, Kevin Driver <kdri...@openjdk.org> wrote:

>> src/java.base/share/classes/javax/crypto/KDF.java line 1:
>> 
>>> 1: /*
>> 
>> I have some overall comments on the implementation of this class:
>> 
>> 1. If I understand correctly, whether DPS is completed depends only on 
>> whether `pairOfSpiAndProv` is null or not. There seems no need to check the 
>> elements inside it using `delegateAndSpiAreInitialized` or whether 
>> `serviceIterator` is null.
>> 2. The type name `Delegate` is confusing. How about just call it 
>> `SpiAndProv`? The field names `pairOfSpiAndProv` and `firstPairOfSpiAndProv` 
>> are also confusing. How about just call them `locked` and `candidate`?
>> 3. There are many places where throws clauses on the 2nd line that are not 
>> indented by 8 spaces.
>
> For (2), the name `Delegate` was chosen by another reviewer. 
> 
> For (3), we need a valid IDE formatting spec. In 2024, we should not be 
> manually indenting. I'll attempt to find a way to specify this in IntelliJ's 
> config.

For (2), I'll see if the another reviewer has a comment.
For (3), my IDE automatically indents 8 chars. It's IntelliJ IDEA of 2024.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/20301#discussion_r1761592695

Reply via email to