RFR: JDK-8281238: TYPE_USE annotations not printed in correct position in toString output
Joe Darcy
darcy at openjdk.java.net
Wed Feb 9 21:55:27 UTC 2022
To use a type annotation on a fully qualified type name, the annotations must appear between the package name and the type:
java.lang. @TypeAnnotation String // good
and *not* before the fully qualified name
@TypeAnnotation java.lang.String // bad
This required ordering is not preserved in the toString output of TypeMirrors in annotation processing. This changeset corrects that and updates a few tests that assume the older formatting.
(This listed update to the given toString method is necessary; I don't believe any of the other Type toString methods also need to be updated, but some might need updating too.)
-------------
Commit messages:
- Appease jcheck.
- Update copyright and add bug ids to tests.
- JDK-8281238: TYPE_USE annotations not printed in correct position in toString output
Changes: https://git.openjdk.java.net/jdk/pull/7411/files
Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=7411&range=00
Issue: https://bugs.openjdk.java.net/browse/JDK-8281238
Stats: 19 lines in 4 files changed: 8 ins; 0 del; 11 mod
Patch: https://git.openjdk.java.net/jdk/pull/7411.diff
Fetch: git fetch https://git.openjdk.java.net/jdk pull/7411/head:pull/7411
PR: https://git.openjdk.java.net/jdk/pull/7411
More information about the compiler-dev
mailing list