This is the mail archive of the
libc-help@sourceware.org
mailing list for the glibc project.
Re: regexec pattern matching
- From: Florian Weimer <fweimer at redhat dot com>
- To: Anand Akhare <anan dot akhare at gmail dot com>
- Cc: libc-help at sourceware dot org
- Date: Tue, 04 Dec 2018 15:54:43 +0100
- Subject: Re: regexec pattern matching
- References: <CACWLfGL2SCtVixe3xzrU=6DyCJGSf3X46Xa5dHeAvx8AOcSDxQ@mail.gmail.com>
* Anand Akhare:
> Hello,
> regexec matching pattern against buffer throughout complete length
> and skips for those that doesn't match until match is found.
> Is it possible to get match for first character and if match fails, it
> returns fail rather than going forward to next characters.
> In summary, only start of buffer should b considered for match.
I think glibc's non-POSIX matching interfaces (re_search etc.) support
this via the range argument, but I have not tired this.
Thanks,
Florian