You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@netbeans.apache.org by "Bob Allison (Jira)" <ji...@apache.org> on 2020/12/25 10:53:00 UTC

[jira] [Created] (NETBEANS-5184) NullPointerException at org.netbeans.modules.java.source.save.Reformatter$Pretty.scan

Bob Allison created NETBEANS-5184:
-------------------------------------

             Summary: NullPointerException at org.netbeans.modules.java.source.save.Reformatter$Pretty.scan
                 Key: NETBEANS-5184
                 URL: https://issues.apache.org/jira/browse/NETBEANS-5184
             Project: NetBeans
          Issue Type: Bug
    Affects Versions: 12.2, 12.0
            Reporter: Bob Allison
         Attachments: messages.log

NOTE: This is consistent behavior

I typed "fori" and pressed Tab. Instead of auto-completing the for loop it produced this error:

java.lang.NullPointerExceptionjava.lang.NullPointerException at org.netbeans.modules.java.source.save.Reformatter$Pretty.scan(Reformatter.java:587) at org.netbeans.modules.java.source.save.Reformatter$Pretty.visitCase(Reformatter.java:2938) at org.netbeans.modules.java.source.save.Reformatter$Pretty.visitCase(Reformatter.java:397) at jdk.compiler/com.sun.tools.javac.tree.JCTree$JCCase.accept(JCTree.java:1258) at jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:82) at org.netbeans.modules.java.source.save.Reformatter$Pretty.scan(Reformatter.java:601) at org.netbeans.modules.java.source.save.Reformatter$Pretty.handleSwitch(Reformatter.java:2889) at org.netbeans.modules.java.source.save.Reformatter$Pretty.visitSwitch(Reformatter.java:2790) at org.netbeans.modules.java.source.save.Reformatter$Pretty.visitSwitch(Reformatter.java:397) at jdk.compiler/com.sun.tools.javac.tree.JCTree$JCSwitch.accept(JCTree.java:1229) at jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:82) at org.netbeans.modules.java.source.save.Reformatter$Pretty.scan(Reformatter.java:601) at org.netbeans.modules.java.source.save.Reformatter$Pretty.visitBlock(Reformatter.java:1986) at org.netbeans.modules.java.source.save.Reformatter$Pretty.visitBlock(Reformatter.java:397) at jdk.compiler/com.sun.tools.javac.tree.JCTree$JCBlock.accept(JCTree.java:1032) at jdk.compiler/com.sun.source.util.TreePathScanner.scan(TreePathScanner.java:56) at org.netbeans.modules.java.source.save.Reformatter$Pretty.reformat(Reformatter.java:514) at org.netbeans.modules.java.source.save.Reformatter.reformatImpl(Reformatter.java:228) at org.netbeans.modules.java.source.save.Reformatter.reformat(Reformatter.java:101) at org.netbeans.modules.editor.indent.TaskHandler$MimeItem.runTask(TaskHandler.java:550) at org.netbeans.modules.editor.indent.TaskHandler.runTasks(TaskHandler.java:309) at org.netbeans.modules.editor.indent.IndentImpl.reformat(IndentImpl.java:349) at org.netbeans.modules.editor.indent.api.Reformat.reformat(Reformat.java:129) at org.netbeans.lib.editor.codetemplates.CodeTemplateInsertHandler.run(CodeTemplateInsertHandler.java:351) at org.netbeans.editor.GuardedDocument.runAtomicAsUser(GuardedDocument.java:333) at org.netbeans.lib.editor.codetemplates.CodeTemplateInsertHandler.insertTemplate(CodeTemplateInsertHandler.java:261) at org.netbeans.lib.editor.codetemplates.CodeTemplateInsertHandler.processTemplate(CodeTemplateInsertHandler.java:229) at org.netbeans.lib.editor.codetemplates.CodeTemplateManagerOperation.insert(CodeTemplateManagerOperation.java:273) at org.netbeans.lib.editor.codetemplates.api.CodeTemplate.insert(CodeTemplate.java:82) at org.netbeans.lib.editor.codetemplates.AbbrevDetection.expand(AbbrevDetection.java:517) at org.netbeans.lib.editor.codetemplates.AbbrevDetection.expand(AbbrevDetection.java:411) at org.netbeans.lib.editor.codetemplates.AbbrevDetection.checkExpansionKeystroke(AbbrevDetection.java:315) at org.netbeans.lib.editor.codetemplates.AbbrevDetection.keyPressed(AbbrevDetection.java:267) at java.desktop/java.awt.AWTEventMulticaster.keyPressed(AWTEventMulticaster.java:258) at java.desktop/java.awt.AWTEventMulticaster.keyPressed(AWTEventMulticaster.java:257) at java.desktop/java.awt.AWTEventMulticaster.keyPressed(AWTEventMulticaster.java:257) at java.desktop/java.awt.Component.processKeyEvent(Component.java:6590) at java.desktop/javax.swing.JComponent.processKeyEvent(JComponent.java:2849) at java.desktop/java.awt.Component.processEvent(Component.java:6409) at java.desktop/java.awt.Container.processEvent(Container.java:2263) at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:5008) at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2321) at java.desktop/java.awt.Component.dispatchEvent(Component.java:4840) at java.desktop/java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1950) at java.desktop/java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(DefaultKeyboardFocusManager.java:871) at java.desktop/java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:1140) at java.desktop/java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:1010) at java.desktop/java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:836) at java.desktop/java.awt.Component.dispatchEventImpl(Component.java:4889) at java.desktop/java.awt.Container.dispatchEventImpl(Container.java:2321) at java.desktop/java.awt.Window.dispatchEventImpl(Window.java:2772) at java.desktop/java.awt.Component.dispatchEvent(Component.java:4840) at java.desktop/java.awt.EventQueue.dispatchEventImpl(EventQueue.java:772) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:721) at java.desktop/java.awt.EventQueue$4.run(EventQueue.java:715) at java.base/java.security.AccessController.doPrivileged(Native Method) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:95) at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:745) at java.desktop/java.awt.EventQueue$5.run(EventQueue.java:743) at java.base/java.security.AccessController.doPrivileged(Native Method) at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:85) at java.desktop/java.awt.EventQueue.dispatchEvent(EventQueue.java:742) at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:136)[catch] at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:203) at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:124) at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:113) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:109) at java.desktop/java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) at java.desktop/java.awt.EventDispatchThread.run(EventDispatchThread.java:90)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@netbeans.apache.org
For additional commands, e-mail: commits-help@netbeans.apache.org

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