Please use the Apache issue tracking system for new NetBeans issues ( !!
Bug 122900 - Exception if pausing input on an incomplete line
Exception if pausing input on an incomplete line
Product: java
Classification: Unclassified
Component: Compiler
All All
: P2 (vote)
: 6.x
Assigned To: Dusan Balek
Depends on:
  Show dependency treegraph
Reported: 2007-11-27 21:25 UTC by twolf2919
Modified: 2008-06-04 08:35 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT

screenshot of exception and source code in background (259.81 KB, image/png)
2007-11-27 21:32 UTC, twolf2919
sample java class to reproduce error (588 bytes, text/plain)
2008-04-18 14:09 UTC, twolf2919
messages.log file when running 04/19 dev build (36.18 KB, text/plain)
2008-04-21 16:07 UTC, twolf2919

Note You need to log in before you can comment on or make changes to this bug.
Description twolf2919 2007-11-27 21:25:25 UTC
I'm getting the following exception when I simply stop typing for a couple seconds, leaving
the current line in an incomplete state.  If I dismiss the exception dialog and don't do anything,
I don't see any further errors.  If I add/remove a character and pause again, the same exception
pops up.

This is happening on 6.0RC2 on a Fedora5 Linux box running JDK 1.6.02.  I previously reported a
similar error and when Jiri asked me to send the source code in which it happened, I first tried
to reproduce it in that file and couldn't.  I'm afraid that once I exit the IDE, I will not be
able to reproduce either.  I'm including an image of the IDE with the exception and the highlighted
code in hopes that it will be enough to find the bug.

java.lang.ClassCastException:$ResolveError cannot be cast to$ClassSymbol
	at java.util.concurrent.Executors$
	at java.util.concurrent.FutureTask$Sync.innerRun(
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(
	at java.util.concurrent.ThreadPoolExecutor$
[catch] at
Comment 1 twolf2919 2007-11-27 21:32:57 UTC
Created attachment 53573 [details]
screenshot of exception and source code in background
Comment 2 Peter Pis 2007-12-03 15:27:02 UTC
Reassigning to "java" for evaluation.
Comment 3 Jan Lahoda 2007-12-04 09:20:23 UTC
Unfortunately without a reproducible case, it is very unlikely to be fixable.
Comment 4 Jiri Prox 2008-04-11 00:53:57 UTC
moving opened issues from TM <= 6.1 to TM=Dev
Comment 5 pribyl 2008-04-18 12:54:24 UTC
I am closing this as we don't have enough information.

Twolf, please reopen if you still experience difficulties with that and provide some additional info (stack trace, steps
to follow etc.)

Thanks a lot
Comment 6 twolf2919 2008-04-18 14:08:02 UTC
I'm re-opening because it's still a problem - annoying one at that.  I spent a couple minutes and can reproduce it
easily in my environment (which is now 6.01 with the latest updates on Ubuntu 7.10 with JDK 1.6 update 3).

I'm attaching a small source file,  It has a single method with a switch statement in it.  It compiles
just fine.  Now, in the editor, simply double-click the variable columnIndexIn on line 13 (the case statement) and
change that to some letter, say, 'p'.  The syntax highlighter will put red squigglies under it - and then the Exception
occurs.  Every time.  At least in my project :-)
Comment 7 twolf2919 2008-04-18 14:09:24 UTC
Created attachment 60410 [details]
sample java class to reproduce error
Comment 8 pribyl 2008-04-18 15:41:24 UTC
Thank you for the prompt reply.

I just tested your java file on several op. systems and NB builds, still with no luck. It works normally for me.

I tested on:
1, WinXP - 6.1 RC2 (Build 200804170002), jdk 1.6.10
2, Ubuntu 8.04 - 6.1 RC2 (Build 200804170002), jdk 1.6.05
3, Ubuntu 8.04 - 6.0.1 (Build 200801291616), jdk 1.6.05

Thats really weird. In the very first post you wrote that this happened already on 6.0RC2, Fedora, 1.6.02 JDK, so
completely different configuration than now and still the same error, right? 
Comment 9 twolf2919 2008-04-18 15:51:25 UTC
I think it was an identical error - at least they both started with "Resolve$ResolveError cannot be cast to$ClassSymbol.

Now, I should add that I wrote the sample class while I was in a *huge* project (3800 files) - which is the same
condition under which I filed the original bug.  When I have a few moments this afternoon, I can try to create a totally
new project with just this one file in it and see if the error still occurs.

Is there any other way I can help debug this?
Comment 10 Dusan Balek 2008-04-21 09:29:37 UTC
Have you tried to reproduce the issue in the current dev build? Thanks.
Comment 11 twolf2919 2008-04-21 16:05:23 UTC
I just installed the 04/19 dev build and it still does the same thing.  I'm attaching the messages.log, just in case
that is of some help.

Comment 12 twolf2919 2008-04-21 16:07:35 UTC
Created attachment 60500 [details]
messages.log file when running 04/19 dev build
Comment 13 Dusan Balek 2008-04-22 10:44:47 UTC

changeset 0e2cc572dacb in main/nb-javac
changeset aad4c789c843 in main
Comment 14 twolf2919 2008-04-22 14:06:58 UTC
stupid question: is this going to be in 6.1?
Comment 15 Jiri Prox 2008-04-23 08:12:55 UTC
Unfortunately the 6.1 is already prepared for release and no fixes are done in it now. But this would be good candidate
for patch. 

Can you please verify the fix is ok in current dev build? If yes, will we be able to include it in patch. Thanks

(the current dev build can be downloaded at
Comment 16 twolf2919 2008-04-23 14:06:33 UTC
Verified - works in 04/23 dev build.
Thanks a bunch for fixing it.

(am I supposed to mark issue as closed since I opened it?)
Comment 17 Jiri Prox 2008-04-23 14:41:09 UTC
Thanks for verification. The plan is to release patch 1 on May 23rd

Comment 18 pgebauer 2008-04-29 12:20:13 UTC
The fix has been ported into the release61_fixes branch:

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo