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 36191

Summary: StringIndexOutOfBoundsException in org.netbeans.modules.java.gj.V8TreeTranslator
Product: java Reporter: hlavac <hlavac>
Component: UnsupportedAssignee: issues@java <issues>
Status: RESOLVED DUPLICATE    
Severity: blocker    
Priority: P3    
Version: 3.x   
Hardware: PC   
OS: Windows ME/2000   
Issue Type: DEFECT Exception Reporter:
Attachments: Parsing this file will crash the parser
ide.log

Description hlavac 2003-09-18 21:04:41 UTC
After entering a very long string constant 
declaration in Java source file, Java parser will 
crash with 
java.lang.StringIndexOutOfBoundsException at 
org.netbeans.modules.java.gj.V8TreeTranslator.getS
tring(V8TreeTranslator.java:136).

See attached source file for an example.
Comment 1 hlavac 2003-09-18 21:05:31 UTC
Created attachment 11664 [details]
Parsing this file will crash the parser
Comment 2 hlavac 2003-09-18 21:54:45 UTC
If i split the very long string literal into several fragments 
connected with + operator on multiple lines, it will not crash.

There is also some problem in the way the exception is reported - it 
references itself as original cause, causing an infinite loop in the 
exception dialog. See attached ide.log file.
Comment 3 hlavac 2003-09-18 22:00:07 UTC
Created attachment 11666 [details]
ide.log
Comment 4 Tomas Hurka 2003-12-02 10:30:04 UTC

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