On Tue, Apr 22, 2008 at 2:45 PM, Norris Boyd <[EMAIL PROTECTED]> wrote:

>  Fantastic! Thanks for the analysis. Looks like we should be able to
>  compile the JavaScript regexp to a Java regexp and then use
>  java.util.regex.

If you decide not to worry about the character-class extensions, you
can just try to compile the regex as-is, and then if that fails, look
for and change the three missing cases (all of which will cause
regex-compiler errors) and try again.  Since good regexes are more
probable than bad ones (I hope), and the three missing features are
only rarely used, that should speed you up overall.

That also has the advantage that you get all of the Java extensions
for free, some of which are extremely nice, notably the embedded flags
and \A, \z, and \Z (which mean the same as ^ and $ *except* when the m
flag is on).

-- 
GMail doesn't have rotating .sigs, but you can see mine at
http://www.ccil.org/~cowan/signatures

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "JVM 
Languages" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/jvm-languages?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to