Integrated: 8356894: Adjust CreateSymbols to properly handle the newly added @jdk.internal.RequiresIdentity
Jan Lahoda
jlahoda at openjdk.org
Fri May 23 04:38:04 UTC 2025
On Wed, 14 May 2025 14:48:15 GMT, Jan Lahoda <jlahoda at openjdk.org> wrote:
> This patch builds on top of https://github.com/openjdk/jdk/pull/24746, and adds support for `@RequiresIdentity` to `--release`.
>
> Important parts of the patch:
> - `CreateSymbols` now keeps `RuntimeInvisibleTypeAnnotationsAttribute`/`RuntimeVisibleTypeAnnotationsAttribute` annotations
> - for `ct.sym`, the `@RequiresIdentity` annotation is converted to a synthetic `@RequiresIdentity+Annotation`, as for other similar annotations.
> - for parameters, there's a new flag that marks the parameter as "requires identity". The reason is that the other synthetic annotations on symbols used by `ct.sym`/`--release` are normally not added to the model, and hence invisible in the model. Flags are usually used instead of the synthetic annotations in javac. Using this new flag allows us to keep the behavior the same for the `@RequiresIdentity+Annotation`
> - for type variables, the synthetic annotation is filtered out in the API method
This pull request has now been integrated.
Changeset: 9d9e41f5
Author: Jan Lahoda <jlahoda at openjdk.org>
URL: https://git.openjdk.org/jdk/commit/9d9e41f5b4ea70a32871ea6f03a21e3d77212289
Stats: 543 lines in 12 files changed: 513 ins; 14 del; 16 mod
8356894: Adjust CreateSymbols to properly handle the newly added @jdk.internal.RequiresIdentity
Reviewed-by: vromero, liach
-------------
PR: https://git.openjdk.org/jdk/pull/25232
More information about the compiler-dev
mailing list