Regex problem - Pls Help

"Shishir K. Singh" <[email protected]> Mon, 23 Jun 2003 09:55:53 -0400
Newsgroups gmane.comp.jakarta.regexp.user
Message-ID <[email protected]>

>  -----Original Message-----
> From: 	Shishir K. Singh  
> Sent:	Monday, June 23, 2003 9:54 AM
> To:	'[email protected]'
> Subject:	Regex problem - Pls Help
> 
> Hi, 
> 
> I am getting a runtime error for a regex pattern. However, when I use the same string  with Java's 1.4 java.util.regex, it works fine....and I can't use Java 1.4 :(. 
> 
>  Is there something that I am missing with this pattern?? 
> 
> 
> RE detail = new RE("^(.*?)\\s*?=\\s*?(.*?)\\;$");
> 
> 
> gives a runtime error :
> 
> 
> java.lang.ArrayIndexOutOfBoundsException: 65584
>         at org.apache.regexp.RECompiler.setNextOfEnd(RECompiler.java:207)
>         at org.apache.regexp.RECompiler.branch(RECompiler.java:1160)
>         at org.apache.regexp.RECompiler.expr(RECompiler.java:1203)
>         at org.apache.regexp.RECompiler.compile(RECompiler.java:1281)
>         at org.apache.regexp.RE.<init>(RE.java:495)
>         at org.apache.regexp.RE.<init>(RE.java:480)
> 
> 
> The intent is to parse a property file like 
> 
> XXXXXX =    "YYYYYY";
> 
> 
> TIA
> Shishir