On Wed, 1 Jun 2022 18:08:52 GMT, Jonathan Gibbons <j...@openjdk.org> wrote:

>> Hannes Wallnöfer has updated the pull request incrementally with one 
>> additional commit since the last revision:
>> 
>>   Add comment
>
> src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/DeprecatedListWriter.java
>  line 92:
> 
>> 90:                         ? 
>> contents.getContent("doclet.Deprecated_API_Checkbox_Other_Releases")
>> 91:                         : Text.of(release);
>> 92:                 HtmlId htmlId = HtmlId.of("release-" + releaseIndex);
> 
> Note that `releaseIndex` may be an empty string.

I chose the empty string to represent other/uncategorized releases because we 
can't make any assumptions about release naming except that release names are 
non-empty strings. However I recognize that the code above is not great in 
terms of naming and comments. I have added a subsequent commit in which I 
pulled out the checkbox generating code into a separate method, added an 
explanatory comment and only use the empty string where necessary (i.e. not in 
the HtmlId).

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

PR: https://git.openjdk.java.net/jdk/pull/8973

Reply via email to