[Top][All Lists]

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

Re: PCRE regex syntax

From: Eric Blake
Subject: Re: PCRE regex syntax
Date: Sat, 05 May 2007 07:33:22 -0600
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20070221 Thunderbird/ Mnenhy/

Hash: SHA1

According to Daniel Richard G. on 5/4/2007 7:05 PM:
> Hello,
> I've been making good use of m4 1.9 lately, building up my little TeX-like 
> HTML-generating language. As a workaround to the as-yet-unavailable 
> multi-character argument separators, I'm preprocessing the source with 
> s/}{/\037/g and using that control character as my separator. (Looking 
> forward to when this will no longer be necessary!)
> patsubst() has been very useful, but the available regex syntaxes aren't 
> much compared to what Perl can do. The lack of look-ahead/behind assertions 
> has already become an issue for me---a rather frustrating one, especially 
> as PCRE has made Perl syntax a given in so many regex situations outside of 
> Perl proper.
> What are the prospects for m4 2.0 having PCRE-provided Perl regex support 
> in the standard configuration?

Is there a GPL or LGPL implementation of PCRE available for inclusion?  Is
PCRE already available as an installed library (preferably libtool-ized)?

> Would the preference be to have an m4 module 
> that provides the new syntax (once the necessary hooks are in place), or 
> for the base m4 binary to gain the libpcre dependency?

It would have to be a module; Gary already argued against my proposal for
sucking in even regular regex to the base m4 binary to implement
- --warn-macro-sequence for m4 1.9+ (still on my list of things to do; I've
been distracted by other tasks lately, such as getting printf and fflush
to work in a POSIX-compliant manner).

> (I suspect that the manner in which the third-party dependency is handled 
> is of greater concern than the actual implementation/integration.)

It would be similar to how the third-party gmp library is handled for the
mpeval module.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             address@hidden
Version: GnuPG v1.4.5 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org


reply via email to

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