From 7dcc9481d1b2715459903e8c36b1c8b22cbbf94d Mon Sep 17 00:00:00 2001 From: jhugunin Date: Tue, 22 Apr 2003 17:31:00 +0000 Subject: [PATCH] fix for Bugzilla Bug 36736 compiler error expected for implemented abstract pointcuts (using declaredModifiers instead of modifiers so interfaces don't cause trouble) --- .../internal/compiler/ast/PointcutDeclaration.java | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/PointcutDeclaration.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/PointcutDeclaration.java index fc4551ec6..9579cc87e 100644 --- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/PointcutDeclaration.java +++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/PointcutDeclaration.java @@ -13,6 +13,8 @@ package org.aspectj.ajdt.internal.compiler.ast; +import java.lang.reflect.Modifier; + import org.aspectj.ajdt.internal.compiler.lookup.EclipseFactory; import org.aspectj.ajdt.internal.core.builder.EclipseSourceContext; import org.aspectj.weaver.AjAttribute; @@ -77,12 +79,14 @@ public class PointcutDeclaration extends MethodDeclaration { public void resolveStatements() { if (isAbstract()) { this.modifiers |= AccSemicolonBody; - if (pointcutDesignator != null) { - scope.problemReporter().signalError(sourceStart, sourceEnd, "abstract pointcut can't have body"); - } - } + } + if (binding == null || ignoreFurtherInvestigation) return; + + if (Modifier.isAbstract(this.declaredModifiers)&& (pointcutDesignator != null)) { + scope.problemReporter().signalError(sourceStart, sourceEnd, "abstract pointcut can't have body"); + } if (pointcutDesignator != null) { pointcutDesignator.finishResolveTypes(this, this.binding, arguments.length, -- 2.39.5