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 146205 - [65cat] NullPointerException at com.sun.tools.javac.comp.Flow.visitClassDef
Summary: [65cat] NullPointerException at com.sun.tools.javac.comp.Flow.visitClassDef
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Compiler (show other bugs)
Version: 6.x
Hardware: All All
: P1 blocker (vote)
Assignee: Dusan Balek
URL: http://statistics.netbeans.org/except...
Keywords:
: 146206 (view as bug list)
Depends on:
Blocks: 152191
  Show dependency tree
 
Reported: 2008-09-04 15:32 UTC by ulfzibis
Modified: 2009-07-10 13:19 UTC (History)
15 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 105467


Attachments
stacktrace (1.84 KB, text/plain)
2008-09-04 15:32 UTC, ulfzibis
Details
stacktrace (1.80 KB, text/plain)
2008-09-07 07:30 UTC, bburette
Details
stacktrace (3.79 KB, text/plain)
2008-09-08 11:49 UTC, ulfzibis
Details
stacktrace (1.82 KB, text/plain)
2008-09-08 12:14 UTC, ulfzibis
Details
stacktrace (1.88 KB, text/plain)
2008-09-13 11:45 UTC, exlons
Details
stacktrace (1.88 KB, text/plain)
2008-09-13 11:51 UTC, exlons
Details
stacktrace (2.70 KB, text/plain)
2008-09-15 00:44 UTC, _ gtzabari
Details
stacktrace (3.43 KB, text/plain)
2009-04-28 19:00 UTC, misterm
Details
Broken file (17.69 KB, text/plain)
2009-04-28 19:04 UTC, misterm
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ulfzibis 2008-09-04 15:32:46 UTC
Build: NetBeans IDE Dev (Build 200809031401)
VM: Java HotSpot(TM) Client VM, 11.0-b15, Java(TM) SE Runtime Environment, 1.6.0_10-rc-b28
OS: Windows XP, 5.1, x86

User Comments: 
Just copied ~20 lines by ctrl-c ctrl-v in java editor

Stacktrace: 
java.lang.NullPointerException
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:604)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:588)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
        at com.sun.tools.javac.comp.Flow.scanStat(Flow.java:499)
        at com.sun.tools.javac.comp.Flow.scanDef(Flow.java:485)
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:593)
Comment 1 ulfzibis 2008-09-04 15:32:51 UTC
Created attachment 69064 [details]
stacktrace
Comment 2 Peter Pis 2008-09-04 15:35:21 UTC
Reassigning to java.
Comment 3 ulfzibis 2008-09-04 15:49:31 UTC
*** Issue 146206 has been marked as a duplicate of this issue. ***
Comment 4 bburette 2008-09-07 07:29:59 UTC
Build: NetBeans IDE Dev (Build 200809051401)
VM: Java HotSpot(TM) Client VM, 10.0-b22, Java(TM) SE Runtime Environment, 1.6.0_06-b02
OS: Windows XP, 5.1, x86

User Comments: 


Stacktrace: 
java.lang.NullPointerException
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:604)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:588)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
        at com.sun.tools.javac.comp.Flow.scanStat(Flow.java:499)
        at com.sun.tools.javac.comp.Flow.scanDef(Flow.java:485)
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:593)
Comment 5 bburette 2008-09-07 07:30:03 UTC
Created attachment 69243 [details]
stacktrace
Comment 6 ulfzibis 2008-09-08 11:49:19 UTC
Build: NetBeans IDE Dev (Build 200809031401)
VM: Java HotSpot(TM) Client VM, 11.0-b15, Java(TM) SE Runtime Environment, 1.6.0_10-rc-b28
OS: Windows XP, 5.1, x86

User Comments: 


Stacktrace: 
java.lang.NullPointerException
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:604)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:588)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
        at com.sun.tools.javac.comp.Flow.scanStat(Flow.java:499)
        at com.sun.tools.javac.comp.Flow.scanDef(Flow.java:485)
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:593)
Comment 7 ulfzibis 2008-09-08 11:49:22 UTC
Created attachment 69296 [details]
stacktrace
Comment 8 ulfzibis 2008-09-08 12:14:16 UTC
Build: NetBeans IDE Dev (Build 200809031401)
VM: Java HotSpot(TM) Client VM, 11.0-b15, Java(TM) SE Runtime Environment, 1.6.0_10-rc-b28
OS: Windows XP, 5.1, x86

User Comments: 


Stacktrace: 
java.lang.NullPointerException
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:604)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:588)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
        at com.sun.tools.javac.comp.Flow.scanStat(Flow.java:499)
        at com.sun.tools.javac.comp.Flow.scanDef(Flow.java:485)
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:593)
Comment 9 ulfzibis 2008-09-08 12:14:19 UTC
Created attachment 69300 [details]
stacktrace
Comment 10 exlons 2008-09-13 11:44:56 UTC
Build: NetBeans IDE Dev (Build 200809071401)
VM: Java HotSpot(TM) Client VM, 10.0-b23, Java(TM) SE Runtime Environment, 1.6.0_07-b06
OS: Windows 2003, 5.2, x86

User Comments: 
When I select multi-rows in editor, and try to duplicate these line using short key (ctrl+alt+<downArrow> standard eclipse keymap), then this happed.
OS: Windows2003 server
Version of Netbeans: development version 200809071401
JDK:1.6u7 

Stacktrace: 
java.lang.NullPointerException
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:604)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:588)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
        at com.sun.tools.javac.comp.Flow.scanStat(Flow.java:499)
        at com.sun.tools.javac.comp.Flow.scanDef(Flow.java:485)
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:632)
Comment 11 exlons 2008-09-13 11:45:07 UTC
Created attachment 69801 [details]
stacktrace
Comment 12 exlons 2008-09-13 11:51:09 UTC
Build: NetBeans IDE Dev (Build 200809071401)
VM: Java HotSpot(TM) Client VM, 10.0-b23, Java(TM) SE Runtime Environment, 1.6.0_07-b06
OS: Windows 2003, 5.2, x86

User Comments: 
Re-description:

When I select a whole block of a sub class,such as:
...
private class SubClass extends ViewPanel{
public SubClass(){
super(false);	
}
@Override
...
}
...
 in editor, and try to duplicate these lines in below, using short key(Eclipse key map):
Ctrl+Alt+DownArrow, then this happened!

Stacktrace: 
java.lang.NullPointerException
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:604)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:588)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
        at com.sun.tools.javac.comp.Flow.scanStat(Flow.java:499)
        at com.sun.tools.javac.comp.Flow.scanDef(Flow.java:485)
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:632)
Comment 13 exlons 2008-09-13 11:51:13 UTC
Created attachment 69802 [details]
stacktrace
Comment 14 _ gtzabari 2008-09-15 00:44:45 UTC
Build: NetBeans IDE Dev (Build 200809121401)
VM: Java HotSpot(TM) Client VM, 11.0-b15, Java(TM) SE Runtime Environment, 1.6.0_10-rc2-b31
OS: Windows Vista, 6.0, x86

User Comments: 


Stacktrace: 
java.lang.NullPointerException
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:574)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:588)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
        at com.sun.tools.javac.comp.Flow.visitNewClass(Flow.java:1145)
        at com.sun.tools.javac.tree.JCTree$JCNewClass.accept(JCTree.java:1350)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
Comment 15 _ gtzabari 2008-09-15 00:44:49 UTC
Created attachment 69836 [details]
stacktrace
Comment 16 John Baker 2008-09-20 00:24:07 UTC
Build: NetBeans IDE Dev (Build 200809081401)
VM: Java HotSpot(TM) Client VM, 1.5.0_13-121, Java(TM) 2 Runtime Environment, Standard Edition, 1.5.0_13-b05-241
OS: Mac OS X, 10.4.11, i386

User Comments:
jbaker: Editing text and I accidently selected some text and replaced the text with other text.

exlons: When I select multi-rows in editor, and try to duplicate these line using short key (ctrl+alt+<downArrow> standard eclipse keymap), then this happed.
OS: Windows2003 server
Version of Netbeans: development version 200809071401
JDK:1.6u7

exlons: Re-description:

When I select a whole block of a sub class,such as:
...
private class SubClass extends ViewPanel{
public SubClass(){
super(false);	
}
@Override
...
}
...
 in editor, and try to duplicate these lines in below, using short key(Eclipse key map):
Ctrl+Alt+DownArrow, then this happened!

GUEST: Occured when copying and pasting source code.

ulfzibis: Happened on Startup

jbaker: Editing text and I accidently selected some text and replaced the text with other text.



Stacktrace: 
java.lang.NullPointerException
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:574)
        at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:588)
        at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
        at com.sun.tools.javac.comp.Flow.scanStat(Flow.java:499)
        at com.sun.tools.javac.comp.Flow.scanDef(Flow.java:485)
        at com.sun.tools.javac.comp.Flow.visitClassDef(Flow.java:632)
Comment 17 Jan Becicka 2008-09-25 10:03:00 UTC
15 duplicates.
Comment 18 Dusan Balek 2008-11-24 10:13:14 UTC
Should be fixed in the current dev build.
Comment 19 Dusan Balek 2008-11-26 13:44:28 UTC
changeset 5fba960e7e1d in main/nb-javac
details: http://hg.netbeans.org/main/nb-javac?cmd=changeset;node=5fba960e7e1d
changeset 09ff15e4aad6 in main
details: http://hg.netbeans.org/main?cmd=changeset;node=09ff15e4aad6
Comment 20 Quality Engineering 2008-11-27 05:35:18 UTC
Integrated into 'main-golden', will be available in build *200811270201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/09ff15e4aad6
User: Dusan Balek <dbalek@netbeans.org>
Log: Issues #117148, #142224, #142829, #144800, #147851, and #146205 fixed.
Comment 21 misterm 2009-04-28 19:00:23 UTC
Build: NetBeans IDE 6.7 Beta (Build 200904242137)
VM: Java HotSpot(TM) Client VM, 10.0-b19, Java(TM) SE Runtime Environment, 1.6.0_04-b12
OS: Windows XP, 5.1, x86

User Comments: 


Stacktrace: 
org.netbeans.modules.parsing.spi.ParseException
        at org.netbeans.modules.parsing.impl.TaskProcessor.runUserTask(TaskProcessor.java:191)
        at org.netbeans.modules.parsing.impl.TaskProcessor.runWhenScanFinished(TaskProcessor.java:220)
        at org.netbeans.modules.parsing.api.ParserManager.parseWhenScanFinished(ParserManager.java:106)
        at org.netbeans.modules.editor.java.JavaCompletionProvider$JavaCompletionQuery.query(JavaCompletionProvider.java:277)
        at org.netbeans.spi.editor.completion.support.AsyncCompletionTask.run(AsyncCompletionTask.java:218)
        at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:573)
Comment 22 misterm 2009-04-28 19:00:34 UTC
Created attachment 81110 [details]
stacktrace
Comment 24 misterm 2009-04-28 19:04:37 UTC
Created attachment 81111 [details]
Broken file
Comment 25 Michel Graciano 2009-05-04 17:28:41 UTC
P1 since the issue has more then 50 report exceptions.
Comment 26 Dusan Balek 2009-05-05 08:03:01 UTC
Fixed in jet-main.

http://hg.netbeans.org/jet-main/rev/da9eb37ee0df

changeset c0b9686c2469 in main/nb-javac
details: http://hg.netbeans.org/main/nb-javac?cmd=changeset;node=c0b9686c2469
Comment 27 Quality Engineering 2009-05-07 07:56:01 UTC
Integrated into 'main-golden', will be available in build *200905070201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/da9eb37ee0df
User: Dusan Balek <dbalek@netbeans.org>
Log: Issues #146205, #153664, #161870, #161915, #162097, #162302, #162451, #163931, and #163989 fixed.