Community
Participate
Working Groups
Build: 20020404 If you move a Java file that has errors in it from a source folder to somewhere not on the build path the errors remain. Then if you rebuild all, the error disappears. Moving the file to its previous location produces an error again. To reproduce this problem: 1. Start with a new workspace 2. Switch to Java perspective 3. Create a Java project 4. Create a source folder "src", set the output folder to "bin" 5. Create another folder "not-src", but do not put it on the build path 6. Create a Java file in src, Foo.java. 7. Make an error in Foo.java. 8. Save, autobuild runs and you should get an error. (expected) 9. Move (either drag & drop, or move... from the popup) Foo.java to the folder not-src 10. The error remains, even though the file is no longer being built. (<-- NOT expected) 11. Rebuild all, the error disappears (expected) 12. Move Foo.java back, the error reappears (expected)
Markers are attached to a resource and move with the resource. When the file is moved out of the class path then the problem markers should be removed. Moving to JDT CORE for comment.
We are addressing the case where a JAVA file becomes a non-java one (see bug 2857). And this scenario is very similar to the other issue. Now we cannot easily get rid of markers in the JavaModel update, since this one is implemented in term of POST_CHANGE event, where the resource tree is locked. Post 2.0, we might want to revisit this and move the JavaModel update onto the PRE/POST_AUTO_BUILD change notification.
Will reconsider post 2.0
*** Bug 14193 has been marked as a duplicate of this bug. ***
Reopening
Clearing resolution
*** This bug has been marked as a duplicate of 2857 ***