Community
Participate
Working Groups
Due to the use of IProgramElements to create handles (comment #15 of bug 141730) there is a problem with the pointcut used by/uses pointcut relationship. This patch changed places where handles were created for given source locations to first finding the corresponding ipe for the source location within the hierarchy and then creating the handle for this ipe. This works provided the ipe exists in the hierarcy. When it comes to the relationship map all relationships bar the uses pointcut/pointcut used by relationship are created once the hierarchy is built. However, with the uses pointcut/pointcut used by relationship this is added as part of the visitor, namely whilst the hierarchy is being created. If the corresponding pointcut doesn't exist yet then a file node is returned (due to the implementation of AspectJElementHierarchy.findElementForSourceLine(ISourceLocation)) and it is this which is added to the relationship map. Therefore, we need to investigate moving the creation of this relationship to the place when other relationships are created.
Created attachment 45005 [details] zip containing patches to remove rel as a temporary solution A short term solution is to remove the uses pointcut/pointcut used by relationship for the time being. This can be done by setting the flag AsmHierarchyBuilder.shouldAddUsesPointcut to be false. This requires a few tests to check for different things depending on the value of this flag. The attached zip file contains patches to do this: -pr148027-ajde-patch.txt: apply to the ajde project -pr148027-ajdt-core-patch.txt: apply to the org.aspectj.ajdt.core project -pr148027-tests-patch.txt: apply to the tests project
patches from comment #1 in.