mbien commented on issue #3667:
URL: https://github.com/apache/netbeans/issues/3667#issuecomment-2130997738

   i can still reproduce the NPE in NB 22, however the freeze should not happen 
anymore. You had likely at work a "on save" action enabled, like formatting or 
import fixing, in past this could cause issues if javac failed during that 
action.
   
   updated stacktrace:
   
   <details>
   
   ```
   Caused: java.lang.NullPointerException: Cannot invoke 
"com.sun.tools.javac.code.Type.hasTag(com.sun.tools.javac.code.TypeTag)" 
because the return value of "com.sun.tools.javac.code.Type.getEnclosingType()" 
is null
        at com.sun.tools.javac.code.Symbol.hasOuterInstance(Symbol.java:508)
        at 
org.netbeans.modules.java.source.PostFlowAnalysis.visitClassDef(PostFlowAnalysis.java:114)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:814)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:50)
        at 
org.netbeans.modules.java.source.PostFlowAnalysis.scan(PostFlowAnalysis.java:104)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:58)
        at 
com.sun.tools.javac.tree.TreeScanner.visitClassDef(TreeScanner.java:120)
        at 
org.netbeans.modules.java.source.PostFlowAnalysis.visitClassDef(PostFlowAnalysis.java:116)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:814)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:50)
        at 
org.netbeans.modules.java.source.PostFlowAnalysis.scan(PostFlowAnalysis.java:104)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:58)
        at 
com.sun.tools.javac.tree.TreeScanner.visitTopLevel(TreeScanner.java:67)
        at 
com.sun.tools.javac.tree.JCTree$JCCompilationUnit.accept(JCTree.java:553)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:50)
        at 
org.netbeans.modules.java.source.PostFlowAnalysis.scan(PostFlowAnalysis.java:104)
        at 
org.netbeans.modules.java.source.PostFlowAnalysis.analyze(PostFlowAnalysis.java:90)
        at 
org.netbeans.modules.java.source.parsing.JavacParser.moveToPhase(JavacParser.java:765)
        at 
org.netbeans.modules.java.source.parsing.JavacParser.getResult(JavacParser.java:536)
        at 
org.netbeans.modules.java.source.parsing.JavacParser.getResult(JavacParser.java:140)
        at 
org.netbeans.modules.parsing.impl.TaskProcessor.callGetResult(TaskProcessor.java:608)
        at 
org.netbeans.modules.parsing.impl.SourceCache.getResult(SourceCache.java:241)
        at 
org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.run(TaskProcessor.java:775)
        at org.openide.util.lookup.Lookups.executeWith(Lookups.java:288)
        at 
org.netbeans.modules.parsing.impl.TaskProcessor$RequestPerformer.execute(TaskProcessor.java:702)
   [catch] at 
org.netbeans.modules.parsing.impl.TaskProcessor$CompilationJob.run(TaskProcessor.java:663)
        at 
java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
        at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
        at 
org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:1420)
        at 
org.netbeans.modules.openide.util.GlobalLookup.execute(GlobalLookup.java:45)
        at org.openide.util.lookup.Lookups.executeWith(Lookups.java:287)
        at 
org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:2035)
   
   ```
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to