This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 257480

Summary: NullPointerException at com.sun.source.util.TreePath.<init>
Product: third-party Reporter: mps77 <mps77>
Component: -- Other --Assignee: issues@third-party <issues>
Status: NEW ---    
Severity: normal CC: alied, michbarsinai
Priority: P3    
Version: 8.2   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter: 222041
Attachments: stacktrace
stacktrace
stacktrace
stacktrace
stacktrace

Description mps77 2016-01-08 13:56:20 UTC
Build: NetBeans IDE Dev (Build 201601070002)
VM: Java HotSpot(TM) Client VM, 25.72-b05, Java(TM) SE Runtime Environment, 1.8.0_72-ea-b05
OS: Windows 7

User Comments:
mps77: type:
int w.t <ctrl+space>

context:
W w = new W();
for (...) {
  if (..) {
     if (..) {
       int w.t
}




Stacktrace: 
java.lang.NullPointerException
   at com.sun.source.util.TreePath.<init>(TreePath.java:107)
   at org.netbeans.modules.java.editor.ext.fold.ShorteningFold$Visitor.visitVariable(ShorteningFold.java:254)
   at org.netbeans.modules.java.editor.ext.fold.ShorteningFold$Visitor.visitVariable(ShorteningFold.java:127)
   at com.sun.tools.javac.tree.JCTree$JCVariableDecl.accept(JCTree.java:944)
   at com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:72)
   at org.netbeans.api.java.source.support.CancellableTreePathScanner.scan(CancellableTreePathScanner.java:94)
Comment 1 mps77 2016-01-08 13:56:22 UTC
Created attachment 158064 [details]
stacktrace
Comment 2 alied 2016-09-06 12:36:43 UTC
Created attachment 161921 [details]
stacktrace

invoking code completion
Comment 3 Dusan Balek 2016-09-13 08:24:28 UTC
ShorteningFold$Visitor should not pass null value as a parent path to the TreePath constructor.
Comment 4 michbarsinai 2016-09-13 08:39:51 UTC
Created attachment 162021 [details]
stacktrace

Closed a java editor tab.
Comment 5 alied 2016-09-13 18:39:51 UTC
Created attachment 162033 [details]
stacktrace

editing a Java source file with errors
Comment 6 Exceptions Reporter 2017-04-18 04:16:12 UTC
This bug already has 5 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=222041
Comment 7 alied 2017-06-09 15:46:14 UTC
Created attachment 164498 [details]
stacktrace

Not really sure; I just noticed the error notification.
Comment 8 Exceptions Reporter 2017-08-29 00:40:06 UTC
This bug already has 10 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=222041