unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: John Withers <grayarea@reddagger.org>
To: "Pascal J. Bourguignon" <pjb@informatimago.com>
Cc: help-gnu-emacs@gnu.org
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	[thread overview]
Message-ID: <1266547014.7034.106.camel@Frank-Brain> (raw)
In-Reply-To: <87r5oi11bb.fsf@galatea.lan.informatimago.com>

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	other threads:[~2010-02-19  2:36 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-18  6:10 Perl, etc has these "?"-prefix modifiers/codes/whatever. Precisely which does emacs have (and NOT have)? David Combs
2010-02-18 11:46 ` Pascal J. Bourguignon
2010-02-18 16:57   ` John Withers
     [not found]   ` <mailman.1450.1266512270.14305.help-gnu-emacs@gnu.org>
2010-02-18 19:02     ` Pascal J. Bourguignon
2010-02-18 21:38       ` John Bokma
2010-02-18 21:42       ` John Withers
     [not found]       ` <mailman.1460.1266529372.14305.help-gnu-emacs@gnu.org>
2010-02-19  0:53         ` David Combs
2010-02-19  1:06         ` Pascal J. Bourguignon
2010-02-19  2:36           ` John Withers [this message]
     [not found]           ` <mailman.1470.1266547034.14305.help-gnu-emacs@gnu.org>
2010-02-19  6:48             ` Tim X
2010-02-20 21:14               ` John Withers
     [not found]               ` <mailman.1559.1266700478.14305.help-gnu-emacs@gnu.org>
2010-02-23 12:33                 ` Tim Landscheidt
2010-02-18 16:23 ` Tyler Smith
     [not found] ` <mailman.1449.1266510261.14305.help-gnu-emacs@gnu.org>
2010-02-19  0:59   ` David Combs
2010-02-19  3:22     ` Tyler Smith
2010-02-24 19:54 ` Stefan Monnier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1266547014.7034.106.camel@Frank-Brain \
    --to=grayarea@reddagger.org \
    --cc=help-gnu-emacs@gnu.org \
    --cc=pjb@informatimago.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).