Re: RFR: JDK-8298405: Support Markdown in Documentation Comments [v30]
On Mon, 12 Feb 2024 17:44:29 GMT, Pavel Rappo wrote: >> Jonathan Gibbons has updated the pull request incrementally with one >> additional commit since the last revision: >> >> refactor recent new test case in TestMarkdown.java > > src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java > line 1465: > >> 1463: markdownInput.append('\n'); >> 1464: } >> 1465: markdownInput.append(PLACEHOLDER_BLOCK); > > There's quite a lot of overlap with the recently simplified > https://github.com/openjdk/jdk/blob/7c6316886d1ae86a663d996dae373c42281622fd/src/jdk.internal.md/share/classes/jdk/internal/markdown/MarkdownTransformer.java#L220-L238 > > If it's impractical to factor out the common bits, maybe we could at least > make the respective parts of HtmlDocletWriter as close as possible to those > of MarkdownTransformer. I think it is impractical to factor out the common bits, but I will look at the possibility of making the code more similar -- but no promises. - PR Review Comment: https://git.openjdk.org/jdk/pull/16388#discussion_r1486609585
Re: RFR: JDK-8298405: Support Markdown in Documentation Comments [v30]
On Fri, 9 Feb 2024 22:17:43 GMT, Jonathan Gibbons wrote: >> Please review a patch to add support for Markdown syntax in documentation >> comments, as described in the associated JEP. >> >> Notable features: >> >> * support for `///` documentation comments in `JavaTokenizer` >> * new module `jdk.internal.md` -- a private copy of the `commonmark-java` >> library >> * updates to `DocCommentParser` to treat `///` comments as Markdown >> * updates to the standard doclet to render Markdown comments in HTML > > Jonathan Gibbons has updated the pull request incrementally with one > additional commit since the last revision: > > refactor recent new test case in TestMarkdown.java src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/HtmlDocletWriter.java line 1465: > 1463: markdownInput.append('\n'); > 1464: } > 1465: markdownInput.append(PLACEHOLDER_BLOCK); There's quite a lot of overlap with the recently simplified https://github.com/openjdk/jdk/blob/7c6316886d1ae86a663d996dae373c42281622fd/src/jdk.internal.md/share/classes/jdk/internal/markdown/MarkdownTransformer.java#L220-L238 If it's impractical to factor out the common bits, maybe we could at least make the respective parts of HtmlDocletWriter as close as possible to those of MarkdownTransformer. - PR Review Comment: https://git.openjdk.org/jdk/pull/16388#discussion_r1486548869
Re: RFR: JDK-8298405: Support Markdown in Documentation Comments [v30]
> Please review a patch to add support for Markdown syntax in documentation > comments, as described in the associated JEP. > > Notable features: > > * support for `///` documentation comments in `JavaTokenizer` > * new module `jdk.internal.md` -- a private copy of the `commonmark-java` > library > * updates to `DocCommentParser` to treat `///` comments as Markdown > * updates to the standard doclet to render Markdown comments in HTML Jonathan Gibbons has updated the pull request incrementally with one additional commit since the last revision: refactor recent new test case in TestMarkdown.java - Changes: - all: https://git.openjdk.org/jdk/pull/16388/files - new: https://git.openjdk.org/jdk/pull/16388/files/d22668da..3f8aa6b5 Webrevs: - full: https://webrevs.openjdk.org/?repo=jdk&pr=16388&range=29 - incr: https://webrevs.openjdk.org/?repo=jdk&pr=16388&range=28-29 Stats: 42 lines in 1 file changed: 1 ins; 3 del; 38 mod Patch: https://git.openjdk.org/jdk/pull/16388.diff Fetch: git fetch https://git.openjdk.org/jdk.git pull/16388/head:pull/16388 PR: https://git.openjdk.org/jdk/pull/16388