RFR: 8224228: No way to locally suppress lint warnings in parser/tokenizer or preview features [v9]
Archie Cobbs
acobbs at openjdk.org
Thu Feb 6 15:48:57 UTC 2025
> This PR updates the `DeferredLintHandler` so that deferred warnings can be registered during parsing, before any `JCTree` nodes have been created, and it uses this new capability to update the `"preview"` and `"text-blocks"` Lint warnings so that they can be suppressed via `@SuppressWarnings` annotations. More details are provided in additional comments.
>
> Note: This PR depends on (i.e., includes and extends) these other "cleanup" PR's:
> * #23167
> * #23281
> * #23400
Archie Cobbs has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 24 commits:
- Merge branch 'master' into JDK-8224228
- Revert gratuituous whitespace change.
- Merge branch 'JDK-8349155' into JDK-8224228
- Refactor to remove the "log" parameter from Lint.logIfEnabled().
- Fix an inaccurate comment.
- Refactor "dangling-doc-comments" logic to utilize new DeferredLintHandler.
- Fix bugs when mapping lexical deferrals to declarations.
- Refactor to eliminate the unnecessary MandatoryWarningHandler "verbose" field.
- Instead of using EndPosTable, track ending positions of declarations explicitly.
- Merge branch 'JDK-8347958' into JDK-8224228
- ... and 14 more: https://git.openjdk.org/jdk/compare/2b82e2d5...e83c88c2
-------------
Changes: https://git.openjdk.org/jdk/pull/23237/files
Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=23237&range=08
Stats: 855 lines in 26 files changed: 541 ins; 103 del; 211 mod
Patch: https://git.openjdk.org/jdk/pull/23237.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/23237/head:pull/23237
PR: https://git.openjdk.org/jdk/pull/23237
More information about the compiler-dev
mailing list