Community
Participate
Working Groups
when I add my project to Preference->AspectJ Build->Inpath, it report an exception error. ADJT version:2.2.3 Eclipse version:4.3.1 aspectJ-1.8.0.M1.jar aspectjweaver-1.8.0.M1.jar (I have added both jar file above to referenced libraries and Android private Libraries) Error log see below. java.lang.StringIndexOutOfBoundsException at java.lang.String.substring(String.java:1911) at org.aspectj.weaver.bcel.BcelObjectType.getOuterClass(BcelObjectType.java:899) at org.aspectj.weaver.AbstractReferenceTypeDelegate.getFormalTypeParametersFromOuterClass(AbstractReferenceTypeDelegate.java:108) at org.aspectj.weaver.bcel.BcelObjectType.ensureGenericSignatureUnpacked(BcelObjectType.java:767) at org.aspectj.weaver.bcel.BcelObjectType.getS ... 43) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53) Compile error: StringIndexOutOfBoundsException thrown: String index out of range: -1
Any way you could share the project with me (privately?) - I'd love to fix this for 1.8.0 which I'm building in the next 24hours. You could try AspectJ 1.8.0.RC3 which may also make a difference since M1 was using a very beta version of the Eclipse Java8 compiler: http://www.eclipse.org/downloads/download.php?file=/tools/aspectj/aspectj-1.8.0.RC3.jar
A similar problem is maybe described in Bug 475728
Under Bug 475728 I committed a change to 'give up' if we can't work it out. If the class is not providing the right means of expressing what is an inner class via attributes then we then try the string analysis, if that works we will now give up rather than throw the exception.