RFR: 8325075: Enable -Werror for javadoc to fail on any warnings [v2]

Kevin Rushforth kcr at openjdk.org
Thu Mar 21 18:04:42 UTC 2024


> Now that the last of the javadoc warnings are fixed or suppressed, it is time to enable `-Werror` so that new javadoc warnings don't creep into our code base. The GHA run was successful.
> 
> You can see the `-Werror` doing its job in the following GHA workflow run on my [bad-8325075-javadoc-werror](https://github.com/kevinrushforth/jfx/tree/bad-8325075-javadoc-werror) branch, which has the patch from this PR applied on a base without Andy's fix for the last of the javadoc warnings:
> 
> https://github.com/kevinrushforth/jfx/actions/runs/8159524643/job/22304043414
> 
> That build fails with the expected error:
> 
> 
> 2024-03-05T16:23:29.6264357Z /home/runner/work/jfx/jfx/jfx/modules/javafx.web/src/main/java/javafx/scene/web/WebErrorEvent.java:125: warning: no comment
> 2024-03-05T16:23:29.6265947Z     private final String message;
> 2024-03-05T16:23:29.6266448Z                          ^
> 2024-03-05T16:23:29.6267675Z /home/runner/work/jfx/jfx/jfx/modules/javafx.web/src/main/java/javafx/scene/web/WebEvent.java:80: warning: no comment
> 2024-03-05T16:23:29.6269004Z     private final T data;
> 2024-03-05T16:23:29.6269667Z                     ^
> 2024-03-05T16:23:31.7938955Z error: warnings found and -Werror specified
> 2024-03-05T16:23:31.7939652Z Problems generating Javadoc.
> 2024-03-05T16:23:31.7940244Z 1 error
> 2024-03-05T16:23:31.7940590Z 91 warnings

Kevin Rushforth 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 three additional commits since the last revision:

 - Add DOC_WERROR flag (default="true") to allow javadoc -Werror to be disabled
 - Merge branch 'master' into 8325075-javadoc-werror
 - 8325075: Enable -Werror for javadoc to fail on any warnings

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

Changes:
  - all: https://git.openjdk.org/jfx/pull/1390/files
  - new: https://git.openjdk.org/jfx/pull/1390/files/42a329dd..64d434ea

Webrevs:
 - full: https://webrevs.openjdk.org/?repo=jfx&pr=1390&range=01
 - incr: https://webrevs.openjdk.org/?repo=jfx&pr=1390&range=00-01

  Stats: 11716 lines in 200 files changed: 4354 ins; 1563 del; 5799 mod
  Patch: https://git.openjdk.org/jfx/pull/1390.diff
  Fetch: git fetch https://git.openjdk.org/jfx.git pull/1390/head:pull/1390

PR: https://git.openjdk.org/jfx/pull/1390


More information about the openjfx-dev mailing list