diff options
author | aclement <aclement> | 2005-01-19 09:36:46 +0000 |
---|---|---|
committer | aclement <aclement> | 2005-01-19 09:36:46 +0000 |
commit | 71966e3348a05cb99b88885b8e6b751cc61a638e (patch) | |
tree | c55bfb4bd3c329fbd466f4d5232131a4b0cf1871 /weaver | |
parent | 0c8315087053985cae6defeaa2e3f9377968de88 (diff) | |
download | aspectj-71966e3348a05cb99b88885b8e6b751cc61a638e.tar.gz aspectj-71966e3348a05cb99b88885b8e6b751cc61a638e.zip |
Fix for Bug 82570: Weaved code does not include debug lines
Diffstat (limited to 'weaver')
-rw-r--r-- | weaver/src/org/aspectj/weaver/bcel/LazyMethodGen.java | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/weaver/src/org/aspectj/weaver/bcel/LazyMethodGen.java b/weaver/src/org/aspectj/weaver/bcel/LazyMethodGen.java index 88f397818..5da038ef6 100644 --- a/weaver/src/org/aspectj/weaver/bcel/LazyMethodGen.java +++ b/weaver/src/org/aspectj/weaver/bcel/LazyMethodGen.java @@ -970,7 +970,14 @@ public final class LazyMethodGen { (InstructionHandle) localVariableStarts.get(tag), (InstructionHandle) localVariableEnds.get(tag)); } - + + // JAVAC adds line number tables (with just one entry) to generated accessor methods - this + // keeps some tools that rely on finding at least some form of linenumbertable happy. + // Let's check if we have one - if we don't then let's add one. + // TODO Could be made conditional on whether line debug info is being produced + if (gen.getLineNumbers().length==0) { + gen.addLineNumber(gen.getInstructionList().getStart(),1); + } } /** This procedure should not currently be used. |