RFR: JDK-8305713: DocCommentParser: merge blockContent and inlineContent [v5]
Pavel Rappo
prappo at openjdk.org
Tue Apr 18 13:25:55 UTC 2023
On Mon, 17 Apr 2023 21:29:53 GMT, Jonathan Gibbons <jjg at openjdk.org> wrote:
>> Please review a cleanup in DocCommentParser to merge blockContent and inlineContent into a single method to parse "rich content" in a doc comment.
>>
>> **Note:** This is dependent on PR #13362, to convert `DocCommentParser` to use enhanced switch.
>
> Jonathan Gibbons has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains ten commits:
>
> - Merge remote-tracking branch 'upstream/master' into 8305713.dcp-content
> - Merge
> - Merge branch 'pr/13362' into pr/13362
> - convert additional switch statements
> - JDK-8305673: Convert DocCommentParser to use enhanced switch
> - avoid conflict with dependent PR
> - Merge remote-tracking branch 'upstream/master' into 8305713.dcp-content
> - Merge remote-tracking branch 'upstream/master' into 8305713.dcp-content
> - JDK-8305713: DocCommentParser: merge blockContent and inlineContent
Genuine question: what benefits are there in merging the blockContent method with the inlineContent method?
(See initial, trivial comments inline.)
src/jdk.compiler/share/classes/com/sun/tools/javac/parser/DocCommentParser.java line 170:
> 168:
> 169: /**
> 170: * Reads "rich text" content, consisting of text, html and inline tags,
Nit: HTML
src/jdk.compiler/share/classes/com/sun/tools/javac/parser/DocCommentParser.java line 183:
> 181: * <li>{@code BODY}: the beginning of a block tag, or when readung from
> 182: * an HTML file, the appearance of {@code </main>} (or {@code </body>},
> 183: * as determined by {@link #isEndBody()}
Lost trailing )
src/jdk.compiler/share/classes/com/sun/tools/javac/parser/DocCommentParser.java line 190:
> 188: *
> 189: *
> 190: */
Nit: needless blank lines
src/jdk.compiler/share/classes/com/sun/tools/javac/parser/DocCommentParser.java line 190:
> 188: *
> 189: *
> 190: */
Shouldn't that be POSTAMBLE?
src/jdk.compiler/share/classes/com/sun/tools/javac/parser/DocCommentParser.java line 190:
> 188: *
> 189: *
> 190: */
Typo: readung
src/jdk.compiler/share/classes/com/sun/tools/javac/parser/DocCommentParser.java line 838:
> 836: * <li>cdata: {@code <![CDATA[ ... ]]>}
> 837: * </ul>
> 838: * or
Dangling "or".
-------------
PR Review: https://git.openjdk.org/jdk/pull/13431#pullrequestreview-1390076976
PR Review Comment: https://git.openjdk.org/jdk/pull/13431#discussion_r1170009701
PR Review Comment: https://git.openjdk.org/jdk/pull/13431#discussion_r1170019297
PR Review Comment: https://git.openjdk.org/jdk/pull/13431#discussion_r1170010347
PR Review Comment: https://git.openjdk.org/jdk/pull/13431#discussion_r1170011228
PR Review Comment: https://git.openjdk.org/jdk/pull/13431#discussion_r1170011527
PR Review Comment: https://git.openjdk.org/jdk/pull/13431#discussion_r1170024803
More information about the compiler-dev
mailing list