RFR: JDK-8298405: Support Markdown in Documentation Comments [v6]
Jonathan Gibbons
jjg at openjdk.org
Tue Jan 30 00:05:46 UTC 2024
On Mon, 15 Jan 2024 16:13:38 GMT, Pavel Rappo <prappo at openjdk.org> wrote:
>> Jonathan Gibbons 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 seven additional commits since the last revision:
>>
>> - Merge with upstream/master
>> - Merge remote-tracking branch 'upstream/master' into 8298405.doclet-markdown-v3
>> - Address review comments
>> - Fix whitespace
>> - Improve handling of embedded inline taglets
>> - Customize support for Markdown headings
>> - JDK-8298405: Support Markdown in Documentation Comments
>
> src/jdk.compiler/share/classes/com/sun/tools/javac/parser/DocCommentParser.java line 1295:
>
>> 1293: switch (ch) {
>> 1294: case ' ' -> indent++;
>> 1295: case '\t' -> indent = 4;
>
> Shouldn't it be like this or it does not matter?
> ```suggestion
> case '\t' -> indent += 4;
I did mean `indent = 4`.
It would not mean `indent +=4` because you would have to take preceding character count into account, to round up to a multiple of 4.
But anyway, it's enough to know the indent is 4 or more, meaning the code is looking at an indented code block.
https://spec.commonmark.org/0.30/#indented-code-blocks
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/16388#discussion_r1470390472
More information about the build-dev
mailing list