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 49097 - ClassCastException: org.netbeans.jmi.javamodel.TypeCast$Impl
Summary: ClassCastException: org.netbeans.jmi.javamodel.TypeCast$Impl
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Unsupported (show other bugs)
Version: 4.x
Hardware: PC Windows XP
: P3 blocker (vote)
Assignee: Daniel Prusa
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-15 15:07 UTC by _ gtzabari
Modified: 2007-09-26 09:14 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Stack-trace (3.24 KB, text/plain)
2004-09-15 15:07 UTC, _ gtzabari
Details
Source code that triggers exception (12.97 KB, text/plain)
2004-09-15 15:08 UTC, _ gtzabari
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ gtzabari 2004-09-15 15:07:19 UTC
dev build 200409121800

I run "fix imports" on the attached code and get
the attached exception.
Comment 1 _ gtzabari 2004-09-15 15:07:38 UTC
Created attachment 17658 [details]
Stack-trace
Comment 2 _ gtzabari 2004-09-15 15:08:55 UTC
Created attachment 17659 [details]
Source code that triggers exception
Comment 3 _ gtzabari 2004-09-15 15:11:38 UTC
This is caused by the first "(JTree)" in the following line of code
(which you'll find in the attached source-code):

   (JTree) tree = (JTree) e.getSource();

Basically it is true that there is a compiler error in the code and it
is malformed, but this shouldn't cause exceptions to be thrown.
Comment 4 Daniel Prusa 2004-10-25 16:44:37 UTC
This issue seems to be fixed, I cannot reproduce it in the current
build (it was reliably reproducible in the dev build 200409121800).