Re: JDK 9 RFR of JDK-8162817: Annotation toString output not reusable for source input

2016-08-02 Thread joe darcy
Hi Peter, On 8/2/2016 1:59 AM, Peter Levart wrote: Hi Joe, I wonder why you compare the type obtained from an value.getClass() with class literals for primitive types (lines 174, 176, 178): 165 Class type = value.getClass(); 166 if (!type.isArray()) { 167 //

Re: JDK 9 RFR of JDK-8162817: Annotation toString output not reusable for source input

2016-08-02 Thread Peter Levart
Hi Joe, I wonder why you compare the type obtained from an value.getClass() with class literals for primitive types (lines 174, 176, 178): 165 Class type = value.getClass(); 166 if (!type.isArray()) { 167 // primitive value, string, class, enum const, or

JDK 9 RFR of JDK-8162817: Annotation toString output not reusable for source input

2016-08-01 Thread joe darcy
As pointed out by recent core-libs-dev traffic ([1] [2]), the toString output for annotation objects cannot be directly reused as source input if the annotation values are any of: * Class values of array classes (uses JVM name) * Arrays (output uses brackets ("[]") rather than braces {"{}")