Bad performance of simple regular expression - why??
MarcL
lohse at mpimp-golm.mpg.de
Mon Feb 5 22:23:50 PST 2007
>
> Like Bill said, a sample would be helpful.
>
> The most common mistake is to not precompile the regexp.
> For instance using std.regexp.search with the same pattern string is not
> optimal.
>
> If you're going to be using the same pattern multiple times, then you
> should create a RegExp object once, and then apply it multiple times
> using its search, match etc methods.
>
> Regardless, perl was basically created as a convenient way to use
> regular expressions, so it's implementation could very likely be more
> efficient than D's.
>
> Do perl regexp's handle unicode/utf8 properly these days?
> (Actually, do D's for that matter?)
>
> --bb
here's a link to the sequences.gb file (attaching it didn't work)
http://www.ncbi.nlm.nih.gov/entrez/viewer.fcgi?db=nucleotide&val=76559634
More information about the Digitalmars-d
mailing list