help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Perl, etc has these "?"-prefix modifiers/codes/whatever. Precisely w


From: John Withers
Subject: Re: Perl, etc has these "?"-prefix modifiers/codes/whatever. Precisely which does emacs have (and NOT have)?
Date: Thu, 18 Feb 2010 18:36:54 -0800

On Fri, 2010-02-19 at 02:06 +0100, Pascal J. Bourguignon wrote:

> 
> One difficulty when you try to extend regular expression is that the
> time and space complexity of matching such an extended regular
> expression easily becomes exponential.  In these cases, it may be easier
> to write a parser, than to try to force it thru regular expressions,
> both for the programmer's brain and for the CPU processor...

Sure exponential backtracking can happen, you can write checks for
common cases and aborts, but let's say you don't. Who cares? I can write
things that go exponential for memory or clock ticks in any of the
languages I am even trivially familiar with.

> Otherwise, people will do anything they want to do, theory and
> precendent nonobstant.  This only demonstrate the lack of culture of the
> newcomers.

Or it demonstrates the need to get things done. I can write a regex to
do a transform on 1000 text files in a directory and do the operation
before you have closed the last paren on your parser.

But I do appreciate theoretical purity and those who have the expanses
of free time in which to cultivate it.

john withers





reply via email to

[Prev in Thread] Current Thread [Next in Thread]