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 150130 - IllegalStateException: Region: <6714,6715) not found.
Summary: IllegalStateException: Region: <6714,6715) not found.
Status: RESOLVED DUPLICATE of bug 132615
Alias: None
Product: editor
Classification: Unclassified
Component: Completion & Templates (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Miloslav Metelka
URL: http://statistics.netbeans.org/except...
Keywords:
: 150392 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-10-14 19:25 UTC by bwf93
Modified: 2009-10-26 15:13 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 50046


Attachments
stacktrace (1.72 KB, text/plain)
2008-10-14 19:25 UTC, bwf93
Details

Note You need to log in before you can comment on or make changes to this bug.
Description bwf93 2008-10-14 19:25:20 UTC
Build: NetBeans IDE 6.1 (Build 200805300101)
VM: Java HotSpot(TM) Client VM, 1.5.0_15-b04, Java(TM) 2 Runtime Environment, Standard Edition, 1.5.0_15-b04
OS: Windows XP, 5.1, x86

User Comments:
GUEST: invoked surround statement with try..catch; statement is the only one within public static void main.
freeform web project

chrislundin: adding try catch around both statement and block

baffyofdaffy: I just submitted an error about when pressing c error poped up not I press Ctrl+space after the c and press enter and error poped up again

GUEST: surrounding block of code with try-catch

GUEST: Surrounding a block of code with try-catch through refactoring

GUEST: In the editor, selecting the option "surround with try-catch block".



Stacktrace: 
java.lang.IllegalStateException: Region: <6714,6715) not found.
        at org.netbeans.lib.editor.codetemplates.textsync.TextRegionManager.findRegionIndex(TextRegionManager.java:502)
        at org.netbeans.lib.editor.codetemplates.textsync.TextRegionManager.fixRegionStartOffset(TextRegionManager.java:400)
        at org.netbeans.lib.editor.codetemplates.textsync.TextRegionManager.insertUpdate(TextRegionManager.java:231)
        at org.netbeans.lib.editor.codetemplates.textsync.TextRegionManager$DocListener.insertUpdate(TextRegionManager.java:622)
        at org.netbeans.editor.BaseDocument.insertString(BaseDocument.java:676)
        at org.netbeans.api.java.source.ModificationResult.processDocumentLocked(ModificationResult.java:283)
Comment 1 bwf93 2008-10-14 19:25:35 UTC
Created attachment 71799 [details]
stacktrace
Comment 2 Vitezslav Stejskal 2008-10-15 15:46:24 UTC
Reproducible in a dev build. Here are the steps:

1. type fori<tab>; the template will expand
2. select the expanded template (make sure that you don't terminate the synced editing mode)
3. Alt+Enter and select one of the Surround With... hints

You should now have the IllegalStateException.
Comment 3 Vitezslav Stejskal 2008-10-20 11:46:58 UTC
*** Issue 150392 has been marked as a duplicate of this issue. ***
Comment 4 Exceptions Reporter 2008-10-21 09:48:01 UTC
This issue has already 10 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=50046
Comment 5 Miloslav Metelka 2009-10-26 15:13:06 UTC
This should be dup of issue 132615.

*** This issue has been marked as a duplicate of 132615 ***