diff options
author | Reinier Zwitserloot <reinier@zwitserloot.com> | 2017-12-04 23:45:57 +0100 |
---|---|---|
committer | Reinier Zwitserloot <reinier@zwitserloot.com> | 2017-12-05 00:00:08 +0100 |
commit | ab8e14736f8c3a7cb96ae7351d4bb1818131f2b2 (patch) | |
tree | 43315dfa6e746a9a59244bf4314fcea535045412 /src/delombok | |
parent | a92117574e10a7949bb0262786698d138056360b (diff) | |
download | lombok-ab8e14736f8c3a7cb96ae7351d4bb1818131f2b2.tar.gz lombok-ab8e14736f8c3a7cb96ae7351d4bb1818131f2b2.tar.bz2 lombok-ab8e14736f8c3a7cb96ae7351d4bb1818131f2b2.zip |
[JDK9] fixing delombok’s comment integration in JDK9.
Diffstat (limited to 'src/delombok')
-rw-r--r-- | src/delombok/lombok/delombok/DocCommentIntegrator.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/delombok/lombok/delombok/DocCommentIntegrator.java b/src/delombok/lombok/delombok/DocCommentIntegrator.java index c66ff0ec..c3b07f32 100644 --- a/src/delombok/lombok/delombok/DocCommentIntegrator.java +++ b/src/delombok/lombok/delombok/DocCommentIntegrator.java @@ -29,6 +29,7 @@ import java.util.regex.Pattern; import lombok.javac.CommentInfo; import lombok.javac.Javac; +import lombok.javac.PackageName; import lombok.javac.handlers.JavacHandlerUtil; import com.sun.tools.javac.parser.Tokens.Comment; @@ -120,7 +121,8 @@ public class DocCommentIntegrator { } private JCTree findJavadocableNodeOnOrAfter(JCCompilationUnit unit, int endPos) { - if (unit.pid != null && endPos <= unit.pid.pos) return null; + JCTree pid = PackageName.getPackageNode(unit); + if (pid != null && endPos <= pid.pos) return null; Iterator<JCTree> it = unit.defs.iterator(); while (it.hasNext()) { |