Community
Participate
Working Groups
LocalVariableTable is missing for methods adviced by around execution though that is generated for before execution. So softwares those get method parameter information from class files (such as java2wsdl or eclipse ide) can't get the information. Here is the class which has method advied by two aspects. public class Test{ public void sayHello(String message){ System.out.println(message); } } The aspect(1) which contains "around execution". public aspect TestAroundAspect{ void around(): execution(void Test.sayHello(String)){ proceed(); } } The aspect(2) which contains "before execution". public aspect TestBeforeAspect{ before(): execution(void Test.sayHello(String)){ } } And here are the results generated by ajc and javap. javap results for (1): Compiled from "Test.java" public class Test extends java.lang.Object{ public Test(); LineNumberTable: line 1: 0 LocalVariableTable: Start Length Slot Name Signature 0 5 0 this LTest; public void sayHello(java.lang.String); LineNumberTable: line 1: 0 } javap results for (2): Compiled from "Test.java" public class Test extends java.lang.Object{ public Test(); LineNumberTable: line 1: 0 LocalVariableTable: Start Length Slot Name Signature 0 5 0 this LTest; public void sayHello(java.lang.String); LineNumberTable: line 8: 0 line 9: 13 LocalVariableTable: Start Length Slot Name Signature 6 8 0 this LTest; 6 8 1 message Ljava/lang/String; }
Created attachment 58839 [details] sources, bat files and logs bat files need environment variables JAVA_HOME and ASPECTJ_HOME to run.
*** Bug 173977 has been marked as a duplicate of this bug. ***
quick look for 1.5.4, might get punted to 1.6.0
test and fix committed. Simplest way was to allow LazyMethodGen to recognize that it has encountered an method that no longer has a local variable table and constructs it.