diff options
author | asaha <none@none> | 2014-06-03 08:32:34 -0700 |
---|---|---|
committer | asaha <none@none> | 2014-06-03 08:32:34 -0700 |
commit | 0a5a6e7371a08cfe5a3e43931502418502db07ad (patch) | |
tree | 32d58c710386f626f52f4c674d2c180596e055aa /src/share/classes/sun/reflect | |
parent | 7e658e15c1e27a99668f5c5233ee09e81cfd9f11 (diff) | |
parent | 57ac5a110f8b4dfeb6d3305b2d35887066b9be04 (diff) |
Merge
Diffstat (limited to 'src/share/classes/sun/reflect')
-rw-r--r-- | src/share/classes/sun/reflect/annotation/TypeAnnotationParser.java | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/share/classes/sun/reflect/annotation/TypeAnnotationParser.java b/src/share/classes/sun/reflect/annotation/TypeAnnotationParser.java index 9bd4b6c64..8eab556fd 100644 --- a/src/share/classes/sun/reflect/annotation/TypeAnnotationParser.java +++ b/src/share/classes/sun/reflect/annotation/TypeAnnotationParser.java @@ -75,7 +75,7 @@ public final class TypeAnnotationParser { if (ti.getTarget() == filter) l.add(t); } - TypeAnnotation[] typeAnnotations = l.toArray(new TypeAnnotation[0]); + TypeAnnotation[] typeAnnotations = l.toArray(EMPTY_TYPE_ANNOTATION_ARRAY); return AnnotatedTypeFactory.buildAnnotatedType(type, LocationInfo.BASE_LOCATION, typeAnnotations, @@ -245,7 +245,6 @@ public final class TypeAnnotationParser { if (bounds != null) { int startIndex = 0; AnnotatedType[] res = new AnnotatedType[bounds.length]; - Arrays.fill(res, AnnotatedTypeFactory.EMPTY_ANNOTATED_TYPE); // Adjust bounds index // @@ -276,12 +275,12 @@ public final class TypeAnnotationParser { tInfo.getCount() == typeVarIndex) { l.add(t); } - res[i] = AnnotatedTypeFactory.buildAnnotatedType(bounds[i], - loc, - l.toArray(new TypeAnnotation[0]), - candidates.toArray(new TypeAnnotation[0]), - (AnnotatedElement)decl); } + res[i] = AnnotatedTypeFactory.buildAnnotatedType(bounds[i], + loc, + l.toArray(EMPTY_TYPE_ANNOTATION_ARRAY), + candidates.toArray(EMPTY_TYPE_ANNOTATION_ARRAY), + (AnnotatedElement)decl); } return res; } |