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.
1. Create JFrame 2. Modify code this way (stupid way.This comment has no sense): . . . /** private void exitForm(java.awt.event.WindowEvent evt) { System.exit (0); } */ public static void main (String args[]) { new Visual ().show (); } . . note: Comment body is in guarded block 3. Using PropertySheet Edit JavaDoc comment. Click OK button. You will see Error: Attempt to modify guarded block. It is correct, but look at code. You will see this: //** private void exitForm(java.awt.event.WindowEvent evt) { * System.exit (0); * } */** private void exitForm(java.awt.event.WindowEvent evt) { System.exit (0); } */ public static void main (String args[]) { new Visual ().show (); }
Priority is changed to P4 (normal).
It seems that the bug is in Editor's rollback after it throws BadLocationException. Java module calls PositionBounds.setText() on the text region; the BadLocationException is thrown, but the changes are not rolled back as appropriate.
Only changed version to Development.
Version: 'Dev' -> 3.2
This is duplicate of issue http://www.netbeans.org/issues/show_bug.cgi?id=7700 which was already fixed. In mentioned issue, the CRLF in comment caused that characters AFTER the end of comment were modified (means deleted). And in this case it means that guarded section was incorrectly modified. *** This issue has been marked as a duplicate of 7700 ***
Resolved for 3.3.x or earlier, no new info since then -> closing.
Resolved for 3.4.x or earlier, no new info since then -> closing.