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.
In same file as issue 88412, I am editing a method: public void getControlPoints (int[] xp, int[] yp) { xp[0] = this.x1; xp[1] = this.y1; xp[0] = this.x; xp[1] = y + h; } At the line xp[0] = this.x I had just accepted code completion of x1. I got this.x and the following exception was thrown (my guess is these problems have some connection to the fact that there are references to an undeclared variable 'x' in the file). java.io.IOException at org.netbeans.api.java.source.JavaSource.runUserActionTask(JavaSource.java:377) at org.netbeans.modules.editor.java.JavaCompletionProvider$JavaCompletionQuery.query(JavaCompletionProvider.java:215) at org.netbeans.spi.editor.completion.support.AsyncCompletionTask.run(AsyncCompletionTask.java:195) at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:541) [catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:963) Caused by: java.lang.NullPointerException at com.sun.tools.javac.comp.Enter.getClassEnv(Enter.java:136) at com.sun.tools.javac.api.JavacTrees.getAttrContext(JavacTrees.java:250) at com.sun.tools.javac.api.JavacTrees.getScope(JavacTrees.java:184) at com.sun.tools.javac.api.JavacTrees.getScope(JavacTrees.java:63) at org.netbeans.modules.editor.java.JavaCompletionProvider$JavaCompletionQuery.getCompletionEnvironment(JavaCompletionProvider.java:3216) at org.netbeans.modules.editor.java.JavaCompletionProvider$JavaCompletionQuery.resolveCompletion(JavaCompletionProvider.java:414) at org.netbeans.modules.editor.java.JavaCompletionProvider$JavaCompletionQuery.run(JavaCompletionProvider.java:281) at org.netbeans.modules.editor.java.JavaCompletionProvider$JavaCompletionQuery.run(JavaCompletionProvider.java:81) at org.netbeans.api.java.source.JavaSource.runUserActionTask(JavaSource.java:375) ... 4 more
The same root case as issue 88323. *** This issue has been marked as a duplicate of 88323 ***