Documentation clarification.

This commit is contained in:
Philip.Hazel 2015-12-03 17:19:13 +00:00
parent addec0d2ae
commit 4a4326638d
2 changed files with 11 additions and 8 deletions

View File

@ -370,7 +370,11 @@ displaying fields containing NULLS:
space or a #-type comment that was followed by (?-x), which turns off space or a #-type comment that was followed by (?-x), which turns off
PCRE2_EXTENDED, and there was no subsequent (?x) to turn it on again, PCRE2_EXTENDED, and there was no subsequent (?x) to turn it on again,
pcre2_compile() assumed that (?-x) applied to the whole pattern and pcre2_compile() assumed that (?-x) applied to the whole pattern and
consequently mis-compiled it. This bug was found by the LLVM fuzzer. consequently mis-compiled it. This bug was found by the LLVM fuzzer. The fix
for this bug means that a setting of any of the (?imsxU) options at the start
of a pattern is no longer transferred to the options that are returned by
PCRE2_INFO_ALLOPTIONS. In fact, this was an anachronism that should have
changed when the effects of those options were all moved to compile time.
Version 10.20 30-June-2015 Version 10.20 30-June-2015

View File

@ -1,4 +1,4 @@
.TH PCRE2API 3 "21 November 2015" "PCRE2 10.21" .TH PCRE2API 3 "03 December 2015" "PCRE2 10.21"
.SH NAME .SH NAME
PCRE2 - Perl-compatible regular expressions (revised API) PCRE2 - Perl-compatible regular expressions (revised API)
.sp .sp
@ -1565,11 +1565,10 @@ are as follows:
Return a copy of the pattern's options. The third argument should point to a Return a copy of the pattern's options. The third argument should point to a
\fBuint32_t\fP variable. PCRE2_INFO_ARGOPTIONS returns exactly the options that \fBuint32_t\fP variable. PCRE2_INFO_ARGOPTIONS returns exactly the options that
were passed to \fBpcre2_compile()\fP, whereas PCRE2_INFO_ALLOPTIONS returns were passed to \fBpcre2_compile()\fP, whereas PCRE2_INFO_ALLOPTIONS returns
the compile options as modified by any top-level option settings at the start the compile options as modified by any top-level option settings such as (*UTF)
of the pattern itself. In other words, they are the options that will be in at the start of the pattern itself. For example, if the pattern /(*UTF)abc/ is
force when matching starts. For example, if the pattern /(?im)abc(?-i)d/ is compiled with the PCRE2_EXTENDED option, the result is PCRE2_EXTENDED and
compiled with the PCRE2_EXTENDED option, the result is PCRE2_CASELESS, PCRE2_UTF.
PCRE2_MULTILINE, and PCRE2_EXTENDED.
.P .P
A pattern compiled without PCRE2_ANCHORED is automatically anchored by PCRE2 if A pattern compiled without PCRE2_ANCHORED is automatically anchored by PCRE2 if
the first significant item in every top-level branch is one of the following: the first significant item in every top-level branch is one of the following:
@ -3101,6 +3100,6 @@ Cambridge, England.
.rs .rs
.sp .sp
.nf .nf
Last updated: 21 November 2015 Last updated: 03 December 2015
Copyright (c) 1997-2015 University of Cambridge. Copyright (c) 1997-2015 University of Cambridge.
.fi .fi