[Top][All Lists]

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

Re: How is regex implemented in gawk?

From: arnold
Subject: Re: How is regex implemented in gawk?
Date: Sun, 23 May 2021 12:05:42 -0600
User-agent: Heirloom mailx 12.5 7/5/10

Peng Yu <pengyu.ut@gmail.com> wrote:

> How is awk's regex implemented? Is there a way to reuse some
> implementation in REG_EXTENDED and only add some minimal code include
> these extra features? Or the implementation regex in gawk starts from
> scratch? Thanks.

Gawk uses the regex routines from GLIBC and GNULIB (which are identical).
If you need regex routines and are writing something that will only
be used on systems with GLIBC (= most of the major Linux distributions)
then you can just rely on the copy that's already in the C library.
Do 'man -s 3 regex' for more information.

Otherwise, you can copy the routines from GNULIB.


reply via email to

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