]> source.dussan.org Git - aspectj.git/commitdiff
fixes dumb array cast
authoracolyer <acolyer>
Mon, 11 Jul 2005 09:38:48 +0000 (09:38 +0000)
committeracolyer <acolyer>
Mon, 11 Jul 2005 09:38:48 +0000 (09:38 +0000)
weaver/src/org/aspectj/weaver/TypeVariableReferenceType.java

index 91fde77c56ab3fdca642e352876e327023388ef0..37eed50da67f3167e02af3e26486b73c86624be5 100644 (file)
@@ -27,8 +27,12 @@ public class TypeVariableReferenceType extends BoundedReferenceType {
                this.isSuper = false;
                this.upperBound = (ReferenceType) aTypeVariable.getUpperBound();
                this.lowerBound = (ReferenceType) aTypeVariable.getLowerBound();
-               if (aTypeVariable.getAdditionalInterfaceBounds().length > 0) {
-                       this.additionalInterfaceBounds = (ReferenceType[]) aTypeVariable.getAdditionalInterfaceBounds();
+               TypeX[] ifBounds = aTypeVariable.getAdditionalInterfaceBounds();
+               if (ifBounds.length > 0) {
+                       this.additionalInterfaceBounds = new ReferenceType[ifBounds.length];
+                       for (int i = 0; i < ifBounds.length; i++) {
+                               this.additionalInterfaceBounds[i] = (ReferenceType) ifBounds[i]; 
+                       }
                }
                setDelegate(new ReferenceTypeReferenceTypeDelegate((ReferenceType)aTypeVariable.getUpperBound()));
        }