Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-25 Thread Adam Sotona
On Mon, 24 Apr 2023 22:05:18 GMT, Mandy Chung wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Doc fixes + added null and empty tests > > src/java.base/share/classes/java/lang/constant/ModuleDesc.java line 43: > >>

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-25 Thread Adam Sotona
On Mon, 24 Apr 2023 20:56:03 GMT, Mandy Chung wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Doc fixes + added null and empty tests > > src/java.base/share/classes/java/lang/constant/PackageDesc.java line 30: >

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-25 Thread Adam Sotona
On Mon, 24 Apr 2023 21:59:29 GMT, Mandy Chung wrote: >> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Doc fixes + added null and empty tests > > src/java.base/share/classes/java/lang/constant/ModuleDesc.java line 30: > >>

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-25 Thread Mandy Chung
On Mon, 24 Apr 2023 16:26:02 GMT, Adam Sotona wrote: >> Constants API already provides models for all loadable constants to help >> programs manipulating class files and modelling bytecode instructions. >> However no models of module and package constants are provided by Constants >> API.

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-25 Thread Adam Sotona
On Tue, 25 Apr 2023 07:38:41 GMT, Adam Sotona wrote: > Note that other `*Impl` classes in `java.lang.constant` perform validation in  > their constructors and provide custom `toString()` formatting and they also > don’t use records. BTW: for example `ClassDesc:of(String name)` performs

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-25 Thread Adam Sotona
On Mon, 24 Apr 2023 16:33:58 GMT, Chen Liang wrote: > Note that other `*Impl` classes in `java.lang.constant` perform validation in  > their constructors and provide custom `toString()` formatting and they also > don’t use records. Performing validation in constructors I see as a blocker for

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-24 Thread ExE Boss
On Mon, 24 Apr 2023 16:26:02 GMT, Adam Sotona wrote: >> Constants API already provides models for all loadable constants to help >> programs manipulating class files and modelling bytecode instructions. >> However no models of module and package constants are provided by Constants >> API.

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-24 Thread Chen Liang
On Mon, 24 Apr 2023 16:27:28 GMT, ExE Boss wrote: > Note that other `*Impl` classes in `java.lang.constant` perform validation in  > their constructors and provide custom `toString()` formatting and they also > don’t use records. Records were only added in Java 16; the constant API was added

Re: RFR: 8306729: Add nominal descriptors of modules and packages to Constants API [v3]

2023-04-24 Thread Adam Sotona
> Constants API already provides models for all loadable constants to help > programs manipulating class files and modelling bytecode instructions. > However no models of module and package constants are provided by Constants > API. Every program manipulating class files must implement own