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.
[200408301800; jdk1.5.0-rc-b63] Steps to reproduce: 1.Create projects prj1 and prj2 2.Copy file from prj1 to its default package 3.Press Copy action on the default package 4.Paste it to Source Packages of prj2 5.The invalid package command(package <default package>;) appears on the first line of the copied file - the file is not compilable.
Must be inserted by refactoring code; package view does not do any modifications to file contents.
Cannot reproduce in my build. Jara will check it in tomorrow's build.
JavaDataObject.handleCopy() is responsible for this. Reassigning to java.
Surprisingly this issue is probably project related. We insert our code according to folder name. I cannot reproduce this issue on Windows due to attached exception. Someone is trying to create folder "<default package>". On Linux it is probably possible to create such folder and java module correctly insert corresponding package declaration.
Created attachment 17275 [details] org.openide.filesystems.FSException: Cannot create folder <default package> in C:\.
[200408311800; jdk1.5.0-rc-b63] I am still able to reproduce it on Linux(JDS). On WinXP I got the org.openide.filesystems.FSException: Cannot create folder <default package> in C:\. as Honza.
*** This issue has been marked as a duplicate of 48246 ***
The problem doesn't appear now in build 200409011800;jdk1.5.0-rc-b63. The fix of issue #48246 is integrated and resolves this issue too.