[erlang-questions] regexp sux!

Robert Virding robert.virding@REDACTED
Sun Mar 11 23:14:23 CET 2007


There is a new version of regexp in the pipe which:

- is faster for many operations
- supports subexpressions/submatches
- has a compiled mode which is always faster, although it does not yet 
support submatches.

I am working on a version which will handle all pathological regexps 
efficiently (which Perl and many others don't).

I have handed it over to the OTP crew but don't know how far they have 
got with it (it passes all tests so far).

Robert

Torbjorn Tornkvist wrote:
> Mats Cronqvist wrote:
> 
>>   but i guess the question was really about how to get regexp groups/submatches 
>>to work. AFAIK, in that respect regexp is completely brain dead. i use the 
>>gregexp code by pascal brisset.
>>
>> > gregexp:groups(XX,".*encoding=\"\\([A-Z0-9-]+\\)\".*").
>>{match,["ISO-8859-1"]}
>>
> 
> 
> That's more like it !
> 
> I haven't tried Gaspar Chilingarov regexp lib but I assume
> it is very good too. So why do we have this worthless
> regexp library in OTP? I have never been able to use it
> in any useful way!
> 
> I suggest that regexp in OTP is thrown out in favor of
> one of the other available regexp libraries!
> (or at least make it depreciated and bring in a useful alternative)
> 
> Cheers, Tobbe
> 
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://www.erlang.org/mailman/listinfo/erlang-questions
> 



More information about the erlang-questions mailing list