Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 8 May 2011 18:12:44 -0700 (PDT)
From:      "Pedro F. Giffuni" <giffunip@tutopia.com>
To:        hackers@FreeBSD.org, Gabor Kovesdan <gabor@kovesdan.org>
Cc:        Brooks Davis <brooks@freebsd.org>
Subject:   Re: [RFC] Replacing our regex implementation
Message-ID:  <219007.22756.qm@web113513.mail.gq1.yahoo.com>
In-Reply-To: <4DC7356C.20905@kovesdan.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Hello;

Thanks Gabor for this cool project!

--- On Sun, 5/8/11, Gabor Kovesdan <gabor@kovesdan.org> wrote:
...
> - It doesn't provide the REG_STARTEND macro, which is our
> non-POSIX extension. Still, it is useful and easy to
> implement so it is not a problem either.
 
Our sed requires REG_STARTEND (the illumos guys noted so
when they ported our sed).

While on this you should also look at bin/153257 and check
if TRE supports the sysv legacy delimiters. FWIW, the now
defunct lang/gpc used those delimiters to distinguish
between our sed and GNU sed. There are still more than 20
ports that depend on gsed.

> Now I'm working on this little feature and on building a
> libc with TRE. After that I'll publish a patch for testing
> and will also ask portmgr to run it on the cluster.
> 

It may be interesting, although unnecessarily risky, to
see if diff can also use libtre (it uses GNU regex now),
but you will probably want to see this as a future step.
(NEVERMIND.. you explained this right ahead ;) )

> 
> 3, Adding support for GNU-specific permissive regex syntax
> GNU grep accepts regexes that are invalid in POSIX, like
> [a|]. This is necessary for grep and diff in the base
> system. If we don't have them we can never trow out the GNU
> regex implementation. However, we should not make them
> default, so I'm thinking of implementing them somewhere
> else, e.g. in the previously mentioned library.
> 
> So far, these are the plans, please comments if you have
> something in your mind about it.
> 

Sounds good!

Pedro.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?219007.22756.qm>