From 5229a770a19081ab7bcc478210a6992c9cf13ada Mon Sep 17 00:00:00 2001 From: aclement Date: Sat, 10 Dec 2011 00:53:25 +0000 Subject: [PATCH] added var declaration so it doesnt get skipped by jdt processing --- .../ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java index bd234dd03..aabcc19c0 100644 --- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java +++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/InterTypeMethodDeclaration.java @@ -21,6 +21,7 @@ import org.aspectj.org.eclipse.jdt.internal.compiler.ClassFile; import org.aspectj.org.eclipse.jdt.internal.compiler.CompilationResult; import org.aspectj.org.eclipse.jdt.internal.compiler.ast.Argument; import org.aspectj.org.eclipse.jdt.internal.compiler.ast.CompilationUnitDeclaration; +import org.aspectj.org.eclipse.jdt.internal.compiler.ast.LocalDeclaration; import org.aspectj.org.eclipse.jdt.internal.compiler.ast.TypeReference; import org.aspectj.org.eclipse.jdt.internal.compiler.classfmt.ClassFileConstants; import org.aspectj.org.eclipse.jdt.internal.compiler.codegen.CodeStream; @@ -267,6 +268,8 @@ public class InterTypeMethodDeclaration extends InterTypeDeclaration { for (int a = 0; a < itdArgs.length; a++) { LocalVariableBinding lvb = itdArgs[a].binding; LocalVariableBinding lvbCopy = new LocalVariableBinding(lvb.name, lvb.type, lvb.modifiers, true); + // e37: have to create a declaration so that the check in ClassFile (line 2538) won't skip it + lvbCopy.declaration = new LocalDeclaration(itdArgs[a].name,0,0); codeStream.record(lvbCopy); lvbCopy.recordInitializationStartPC(0); lvbCopy.resolvedPosition = lvb.resolvedPosition; -- 2.39.5