Type annotations on inner type that is an array components
bsrbnd at gmail.com
Mon Jul 30 16:23:49 UTC 2018
On 30 July 2018 at 12:50, B. Blaser <bsrbnd at gmail.com> wrote:
> Hi Werner,
> On 30 July 2018 at 05:31, Werner Dietl <wdietl at gmail.com> wrote:
>> Thanks to Liam for pointing out how to run the tests and, of course, I
>> had missed a case: annotations on the array dimensions.
>> I re-added the arrayTypeTree helper method that was removed in
>> and tier1 tests are now clean, except for some failures that already
>> existed for me.
>> Updated patch below.
> I discovered the suspicious change-set after having submitted the
> first patch as initial direction to search, but I was also septic that
> it might be the final solution...
> I'll take a look at your suggestion and give you my feedback soon.
> Maybe examining existing tests (,,...) and adding missing cases
> would be interesting too?
I've attached your latest patch updated as follows:
* removed the unnecessary loop on array elements (replaced by
recursion on 'typeWithAnnotations()')
* added the 'onlyTypeAnnotations' parameter to 'rewriteArrayType()'
* dropped cosmetic changes (indentation & dead code removal) which can
be later reinstated
* added some test cases
Tier1 is OK (without any failure) but note the different output for
'T6747671.java' which probably means that the fix has side-effects.
What do you think?
>  http://hg.openjdk.java.net/jdk/jdk/file/b7a307084247/test/langtools/tools/javac/annotations/typeAnnotations/referenceinfos
>  http://hg.openjdk.java.net/jdk/jdk/file/b7a307084247/test/langtools/tools/javac/annotations/typeAnnotations/referenceinfos/Fields.java
>> cu, WMD.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 7047 bytes
Desc: not available
More information about the compiler-dev