RFR: 8339260: Move rarely used constants out of ClassFile [v9]
Adam Sotona
asotona at openjdk.org
Wed Sep 25 06:38:35 UTC 2024
On Tue, 24 Sep 2024 17:23:41 GMT, Chen Liang <liach at openjdk.org> wrote:
>> Many constants are cluttered in `ClassFile`. However, only a few of them are ever used by regular users, most notably `ACC_` flags and `JAVA_X_VERSION` constants. All other constants are specific and should live in more local locations, such as getters that return these constants.
>>
>> This simplification of `ClassFile` constants improves user onramp to the Class-File API.
>>
>> Notably, before, if `ClassFile` is static imported, `Opcode` enums must be qualified due to name clashes; this relocation allows `Opcode` enums to be static imported with `ACC_` flags, improving class file writing user experience.
>
> Chen Liang has updated the pull request incrementally with one additional commit since the last revision:
>
> AbstractPoolEntry is broken too
Marked as reviewed by asotona (Reviewer).
-------------
PR Review: https://git.openjdk.org/jdk/pull/20773#pullrequestreview-2327211669
More information about the core-libs-dev
mailing list