On Fri, 3 Feb 2023 18:25:17 GMT, Maurizio Cimadamore <[email protected]>
wrote:
>> Adam Sotona has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Classfile API moved under jdk.internal.classfile package
>
> src/java.base/share/classes/jdk/internal/classfile/CodeBuilder.java line 333:
>
>> 331: * @see #catchingAll
>> 332: */
>> 333: CatchBuilder catching(ClassDesc exceptionType,
>> Consumer<BlockCodeBuilder> catchHandler);
>
> I imagine there are name clashes with Java keyword, hence the `ing` in the
> names. That said, this should probably revisited in a later bikeshedding
> round - as in the current form, the code builder API has most method names
> that are nouns (the thing being built) but it also has some verbs in there
> (trying, catching) which seem odd.
Please raise the naming convention discussion at classfile-api-dev at
openjdk.org
Thanks.
> src/java.base/share/classes/jdk/internal/classfile/Opcode.java line 39:
>
>> 37: */
>> 38: public enum Opcode {
>> 39: NOP(Classfile.NOP, 1, Kind.NOP),
>
> This also duplicates the constants in classfile...
On the contrary, it has been deduplicated. Opcode is referencing numeric
constants stored in Classfile.
-------------
PR: https://git.openjdk.org/jdk/pull/10982