RFR: JDK-8310861: Improve location reporting for javac serial lint warnings [v2]
Joe Darcy
darcy at openjdk.org
Mon Jun 26 01:30:15 UTC 2023
> For a subset of the expanded serial lint warnings ([JDK-8202056](https://bugs.openjdk.org/browse/JDK-8202056), [JDK-8160675](https://bugs.openjdk.org/browse/JDK-8160675)), javac uses the location of the enclosing type rather than the method or field in question.
>
> This PR addresses this by using the idiom of finding the method/field's tree within the type tree being checked.
>
> All langtools regression tests pass when run locally; the intention is to backport this fix to JDK 21 as well.
Joe Darcy has updated the pull request incrementally with one additional commit since the last revision:
Cover additional case.
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/14644/files
- new: https://git.openjdk.org/jdk/pull/14644/files/0f0c3c1f..f9d4b8a2
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=14644&range=01
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=14644&range=00-01
Stats: 7 lines in 2 files changed: 3 ins; 0 del; 4 mod
Patch: https://git.openjdk.org/jdk/pull/14644.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/14644/head:pull/14644
PR: https://git.openjdk.org/jdk/pull/14644
More information about the compiler-dev
mailing list