summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorнаб <nabijaczleweli@nabijaczleweli.xyz>2023-04-20 01:23:04 +0200
committerAlejandro Colomar <alx@kernel.org>2023-04-20 13:17:09 +0200
commit0d120a3c76b4446b194a54387ce0e7a84b208bfd (patch)
treed3ed808545ae871d03f647b0f4a0c7fa00bcf765
parent34bb376e954f61adf9b70c84155d06568d161fd9 (diff)
regex.3: Note that pmatch is still used if REG_NOSUB if REG_STARTEND
In the regexec() signature regmatch_t pmatch[restrict .nmatch], is a simplification. It's actually regmatch_t pmatch[restrict ((.preg->flags & REG_NOSUB) ? 0 : .nmatch) ?: !!(.eflags & REG_STARTEND)], But speccing that would be insane. Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz> Signed-off-by: Alejandro Colomar <alx@kernel.org>
-rw-r--r--man3/regex.36
1 files changed, 4 insertions, 2 deletions
diff --git a/man3/regex.3 b/man3/regex.3
index e8fed5147..d77aac2e7 100644
--- a/man3/regex.3
+++ b/man3/regex.3
@@ -80,9 +80,11 @@ The
.I nmatch
and
.I pmatch
-arguments to
.BR regexec ()
-are ignored if the pattern buffer supplied was compiled with this flag set.
+arguments will be ignored for this purpose (but
+.I pmatch
+may still be used for
+.BR REG_STARTEND ).
.TP
.B REG_NEWLINE
Match-any-character operators don't match a newline.