diff options
author | Andy Clement <andrew.clement@gmail.com> | 2012-08-23 13:05:24 -0700 |
---|---|---|
committer | Andy Clement <andrew.clement@gmail.com> | 2012-08-23 13:05:24 -0700 |
commit | 55ebaa15305cc686c6ed5915ff1115071b3c80bd (patch) | |
tree | 844235fca8f35eb1086cb45607f9a8d0fb4b8c21 /org.aspectj.ajdt.core | |
parent | 76d695ff1a6f8863a1b64f17e38a5ffee170f09f (diff) | |
download | aspectj-55ebaa15305cc686c6ed5915ff1115071b3c80bd.tar.gz aspectj-55ebaa15305cc686c6ed5915ff1115071b3c80bd.zip |
384401
Diffstat (limited to 'org.aspectj.ajdt.core')
-rw-r--r-- | org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ValidateAtAspectJAnnotationsVisitor.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ValidateAtAspectJAnnotationsVisitor.java b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ValidateAtAspectJAnnotationsVisitor.java index 506aabfbf..fa63a3393 100644 --- a/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ValidateAtAspectJAnnotationsVisitor.java +++ b/org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/ValidateAtAspectJAnnotationsVisitor.java @@ -385,6 +385,11 @@ public class ValidateAtAspectJAnnotationsVisitor extends ASTVisitor { try { // +1 to give first char of pointcut string ISourceContext context = new EclipseSourceContext(unit.compilationResult, pcLocation[0] + 1); + if (pointcutExpression == null) { + methodDeclaration.scope.problemReporter().signalError(methodDeclaration.sourceStart, + methodDeclaration.sourceEnd, "the advice annotation must specify a pointcut value"); + return; + } PatternParser pp = new PatternParser(pointcutExpression, context); Pointcut pc = pp.parsePointcut(); pp.checkEof(); |