Summary: | ClassFormatError when targetting nested forEach lambda expressions | ||||||
---|---|---|---|---|---|---|---|
Product: | [Tools] AspectJ | Reporter: | Alexander Kriegisch <Alexander> | ||||
Component: | Compiler | Assignee: | aspectj inbox <aspectj-inbox> | ||||
Status: | RESOLVED FIXED | QA Contact: | |||||
Severity: | normal | ||||||
Priority: | P3 | CC: | aclement, teraoka.yuki | ||||
Version: | 1.8.0 | ||||||
Target Milestone: | 1.8.1 | ||||||
Hardware: | PC | ||||||
OS: | Windows 8 | ||||||
Whiteboard: | |||||||
Attachments: |
|
Description
Alexander Kriegisch
2014-05-21 16:26:52 EDT
The problem really seems to be the Eclipse Java compiler because if I compile my application class separately with javac and perform post-compile weaving upon it, it works with nested lambda 'forEach' and without excluding the lambdas from the pointcut: execution(void de.scrum_master.app.Application.main(String[])) execution(void de.scrum_master.app.Application.lambda$main$1(Map.Entry)) Language code = DE execution(void de.scrum_master.app.Application.lambda$null$0(Map.Entry)) 11 -> elf execution(void de.scrum_master.app.Application.lambda$null$0(Map.Entry)) 12 -> zwölf execution(void de.scrum_master.app.Application.lambda$null$0(Map.Entry)) 13 -> dreizehn execution(void de.scrum_master.app.Application.lambda$main$1(Map.Entry)) Language code = EN execution(void de.scrum_master.app.Application.lambda$null$0(Map.Entry)) 11 -> eleven execution(void de.scrum_master.app.Application.lambda$null$0(Map.Entry)) 12 -> twelve execution(void de.scrum_master.app.Application.lambda$null$0(Map.Entry)) 13 -> thirteen Another workaround is to use JVM option '-noverify'. In Java 8 '-XX:-UseSplitVerifier' is no longer a valid option, but the other one also works. A solution would be preferable to a workaround though. All fixed up. Thanks for the great test case. The problem was the size of the invokedynamic instruction was not being calculated correctly. This led to a bad calculation of the local variable entry. Latest dev builds include the fix (on the website and in the snapshot maven repo). I can confirm that it works now. BTW, where is the development Maven repository? Repo should be at: repo.spring.io/snapshot Thanks for testing the fix. *** Bug 434272 has been marked as a duplicate of this bug. *** |