aboutsummaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
Diffstat (limited to 'src/core')
-rw-r--r--src/core/lombok/javac/handlers/HandleExtensionMethod.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/core/lombok/javac/handlers/HandleExtensionMethod.java b/src/core/lombok/javac/handlers/HandleExtensionMethod.java
index 717afbc5..788a16a0 100644
--- a/src/core/lombok/javac/handlers/HandleExtensionMethod.java
+++ b/src/core/lombok/javac/handlers/HandleExtensionMethod.java
@@ -147,10 +147,15 @@ public class HandleExtensionMethod extends JavacAnnotationHandler<ExtensionMetho
handleMethodCall((JCMethodInvocation) tree);
return super.visitMethodInvocation(tree, p);
}
-
+
private void handleMethodCall(final JCMethodInvocation methodCall) {
JavacNode methodCallNode = annotationNode.getAst().get(methodCall);
+ if (methodCallNode == null) {
+ // This should mean the node does not exist in the source at all. This is the case for generated nodes, such as implicit super() calls.
+ return;
+ }
+
JavacNode surroundingType = upToTypeNode(methodCallNode);
TypeSymbol surroundingTypeSymbol = ((JCClassDecl)surroundingType.get()).sym;