RFR: JDK-8272945: Use snippets in java.compiler documentation [v2]

Jonathan Gibbons jjg at openjdk.java.net
Tue Dec 7 03:05:41 UTC 2021


> Please review a patch to use snippets in the `java.compiler` documentation, instead of a mix of raw HTML and/or `{@code ...}`.  The change is just about the presentation of the code fragments; there are no changes to the normative specifications for the module.
> 
> One of the examples went to extraordinary lengths to include the character sequence `*/` within the example. That example has been replaced by an external snippet in a separate source file, which does not have any restriction on the use of `*/`. However, it does require that the file be excluded from standard compilation, and that is done by setting `EXCLUDES`, once for the "interim" compiler, and once again for the "product" compiler.    Going forward, a better solution might be to modify the `SetupJavaCompilation` macro to ignore all directories whose name is not a valid Java identifier (or, if easier, contains a `-`, such as `doc-files` or `snippet-files`.)

Jonathan Gibbons has updated the pull request incrementally with one additional commit since the last revision:

  Address review comments

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

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/6686/files
  - new: https://git.openjdk.java.net/jdk/pull/6686/files/97cedc9a..27467bf2

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk&pr=6686&range=01
 - incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=6686&range=00-01

  Stats: 3 lines in 2 files changed: 0 ins; 1 del; 2 mod
  Patch: https://git.openjdk.java.net/jdk/pull/6686.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/6686/head:pull/6686

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



More information about the build-dev mailing list