diff options
author | aclement <aclement> | 2010-12-13 20:31:12 +0000 |
---|---|---|
committer | aclement <aclement> | 2010-12-13 20:31:12 +0000 |
commit | bd5cd17934f61a9e626455b424f4004127f38d94 (patch) | |
tree | 0c860e0df3f74ae6045da1ba87b065cb4e486ca7 /weaver | |
parent | 13fff7553a5871b06c8497d5093dae051a3a570a (diff) | |
download | aspectj-bd5cd17934f61a9e626455b424f4004127f38d94.tar.gz aspectj-bd5cd17934f61a9e626455b424f4004127f38d94.zip |
332388: test and fix
Diffstat (limited to 'weaver')
-rw-r--r-- | weaver/src/org/aspectj/weaver/bcel/BcelGenericSignatureToTypeXConverter.java | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/weaver/src/org/aspectj/weaver/bcel/BcelGenericSignatureToTypeXConverter.java b/weaver/src/org/aspectj/weaver/bcel/BcelGenericSignatureToTypeXConverter.java index dc7729830..081bdd5f7 100644 --- a/weaver/src/org/aspectj/weaver/bcel/BcelGenericSignatureToTypeXConverter.java +++ b/weaver/src/org/aspectj/weaver/bcel/BcelGenericSignatureToTypeXConverter.java @@ -14,6 +14,7 @@ package org.aspectj.weaver.bcel; import java.util.HashMap; import java.util.Map; +import org.aspectj.bridge.Message; import org.aspectj.util.GenericSignature; import org.aspectj.util.GenericSignature.SimpleClassTypeSignature; import org.aspectj.weaver.BoundedReferenceType; @@ -161,12 +162,24 @@ public class BcelGenericSignatureToTypeXConverter { if (aTypeArgument.isMinus) { UnresolvedType bound = fieldTypeSignature2TypeX(aTypeArgument.signature, typeParams, world, inProgressTypeVariableResolutions); - ReferenceType rBound = (ReferenceType) world.resolve(bound); + ResolvedType resolvedBound = world.resolve(bound); + if (resolvedBound.isMissing()) { + world.getMessageHandler().handleMessage( + new Message("Unable to find type (for bound): " + resolvedBound.getName(), null, true)); + resolvedBound = world.resolve(UnresolvedType.OBJECT); + } + ReferenceType rBound = (ReferenceType) resolvedBound; return new BoundedReferenceType(rBound, false, world); } else if (aTypeArgument.isPlus) { UnresolvedType bound = fieldTypeSignature2TypeX(aTypeArgument.signature, typeParams, world, inProgressTypeVariableResolutions); - ReferenceType rBound = (ReferenceType) world.resolve(bound); + ResolvedType resolvedBound = world.resolve(bound); + if (resolvedBound.isMissing()) { + world.getMessageHandler().handleMessage( + new Message("Unable to find type (for bound): " + resolvedBound.getName(), null, true)); + resolvedBound = world.resolve(UnresolvedType.OBJECT); + } + ReferenceType rBound = (ReferenceType) resolvedBound; return new BoundedReferenceType(rBound, true, world); } else { return fieldTypeSignature2TypeX(aTypeArgument.signature, typeParams, world, inProgressTypeVariableResolutions); |