Community
Participate
Working Groups
Example: class A extends B class A is available in bytecode class B will be loaded at a later time when we weave class A the weaver complains about missing class. shouldn't be very critical... when weaving class B, which we get now (e.g. via a network classloader), after the vm has tried to resolve class A, the weaver throws a ClassCastException in BcelWorld:addSourceObjectType
Created attachment 17716 [details] addSourceObjectType checks the type before casting proposed fix
for investigation in aj5m3
not generics, postponing ...
Sorry for not getting to look at this sooner. It now turns out the patch is out of date because of all the generics changes. However, I'm quite nervous about what the patch was doing - I wonder what *is* in the type map against that signature if its not a ResolvedType.Name (this inner type has now been changed to be called 'ReferenceType' in CVS). It might be that whatever it is shouldn't have been put into the typemap in the first place - and if thats the case i'd rather fix that than just cope with a rogue entry in the map later on, which might cause us other problems elsewhere... Are you able to recreate this with a recent AspectJ? If so, when the classcastexception occurs, what is it trying to cast?
I managed to get a fix for this tested under bug 112243 - I've put in a fix to stop the rogue entry getting into the typemap and also a guard to prevent us blowing up with no useful info should anything funny like this happen again. fix is available in latest AJ dev build.