[TxMt] Re: TextMate's Regexp has been running for 11hrs so far...

Mel Brands bighype at gmail.com
Wed Apr 20 03:07:38 UTC 2011


Stephen said:

>What's the search expression? Chances are that's what's causing the
>problem. It's very easy to write a simple expression that (in any
>engine) takes a very long time to evaluate. perldoc perlre has some
>examples, IIRC.

Hi!

Search expression was something like:

\{\"[\d\s]+\",\"\",\"[\w\s]+\",\"[\w\s at -_\+]+\"\},

After an hour after I sent that email, I killed the process. I
couldn't let it run anymore... was too frustrating.

I then wrote a quick ruby script and did it that way. It finished in
seconds. TM has some serious issues with newlines... because it runs
100000x faster when the replacement statement has no "\n" characters
and when the text you're running the regexp on is not one long line.
Give it a try on your own test data.

Thank you for a message! I appreciate it for trying to help.

Melanie


More information about the textmate mailing list