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.
Build 20040114 I've invoked rename of some class. It didn't rewrite declaration of array of renamed class. Example: renamed class Bean it didn't rename code like: public Bean[] beans;
It doesn't find some of the class'es occurencies as array, not all. After rename of this class there are thrown ClassCastExceptions.
Created attachment 12929 [details] CCE's stacktrace.
This issue was fixed as a side effect of changes in javacore (introduction of MultipartId) Emane, please verify. Thanks.
I've found that in case of source e.g.: return (Bean[])(ret.toArray(new Bean[] {})); parser still doesn't find occurances of class Bean.
The problem is, that parser cannot resolve MultipartId "Bean" in this case. MultipartId.getParser().getSemanticInfo(token "Bean") returns null Tomasi, can you take a look at it? Thanks
This is still the case. I have investigated it a little bit and found out that the following types of usages of array can be found without problems (I was looking for usages of MethodInfo class): MethodInfo[] methods = generateMethods(); protected abstract MethodInfo[] generateMethods() throws IOException; But the following type of occurence cannot be found: return (MethodInfo[]) methods.toArray(new MethodInfo[methods.size()]); It seems like there is a problem only with expressions in return statement. Or maybe it is a problem with TypeCast and NewArrayExpression. Attached are the sources I've tried it on. I tried to rename org.netbeans.lib.jmi.util.ClassFileGenerator.MethodInfo class. One of the usages that are not found is in AssociationGenerator class line 105.
Created attachment 13888 [details] Sources that can be used to test whether the issue is fixed.
Fixed in meta_2 branch.
Tomas already fixed it
Verified in alpha build.