Community
Participate
Working Groups
Created attachment 254317 [details] Code to reproduce error The attached Java 1.8 code results in the following exception after compilation with ajc and executing the "Main" class: Exception in thread "main" java.lang.AbstractMethodError: Method BImpl.getValue()Ljava/lang/Object; is abstract at BImpl.getValue(BImpl.java) at Main.main(Main.java:9) Steps to reproduce: export CLASSPATH=/opt/aspectj1.8/lib/aspectjrt.jar:. /opt/aspectj1.8/bin/ajc -1.8 *.java java Main Result: Exception in thread "main" java.lang.AbstractMethodError: Method BImpl.getValue()Ljava/lang/Object; is abstract at BImpl.getValue(BImpl.java) at Main.main(Main.java:9)
I guess I should mention that the exact same code compiled with javac executes without throwing the exception. :)
I tried with Eclipse 4.4.0 and it also fails. Since it doesn't fail on more recent eclipses we can assume it is a bug in the Eclipse compiler that we've inherited. When we rebase on a more recent version we'll pick up the fix. I can see the problem is that the default method getValue() in the interface is not getting a bridge method generated alongside it. Thanks for the nice concise testcase
Fixed, I believe by recently picking up JDT changes.