summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorph10 <ph10@6239d852-aaf2-0410-a92c-79f79f948069>2016-06-29 16:52:05 +0000
committerph10 <ph10@6239d852-aaf2-0410-a92c-79f79f948069>2016-06-29 16:52:05 +0000
commit0a7a393d707706b82546ac4f616e4c6eed3c37d7 (patch)
treebdd0d5438163f97e48ec2b419b07489e09c97aaa /src
parentd95b69f8f609e5925ab607f012c228e757ecbcad (diff)
downloadpcre2-0a7a393d707706b82546ac4f616e4c6eed3c37d7.tar.gz
Documentation detrail and make HTML for 10.22-RC1.
git-svn-id: svn://vcs.exim.org/pcre2/code/trunk@538 6239d852-aaf2-0410-a92c-79f79f948069
Diffstat (limited to 'src')
-rw-r--r--src/config.h.generic12
-rw-r--r--src/pcre2.h2
-rw-r--r--src/pcre2.h.generic20
-rw-r--r--src/pcre2.h.in2
-rw-r--r--src/pcre2_compile.c36
-rw-r--r--src/pcre2_config.c2
-rw-r--r--src/pcre2_dfa_match.c4
-rw-r--r--src/pcre2grep.c4
8 files changed, 49 insertions, 33 deletions
diff --git a/src/config.h.generic b/src/config.h.generic
index 744f198..5595998 100644
--- a/src/config.h.generic
+++ b/src/config.h.generic
@@ -111,6 +111,9 @@ sure both macros are undefined; an emulation function will then be used. */
/* Define to 1 if you have the <sys/types.h> header file. */
/* #undef HAVE_SYS_TYPES_H */
+/* Define to 1 if you have the <sys/wait.h> header file. */
+/* #undef HAVE_SYS_WAIT_H */
+
/* Define to 1 if you have the <unistd.h> header file. */
/* #undef HAVE_UNISTD_H */
@@ -203,7 +206,7 @@ sure both macros are undefined; an emulation function will then be used. */
#define PACKAGE_NAME "PCRE2"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "PCRE2 10.21"
+#define PACKAGE_STRING "PCRE2 10.22-RC1"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "pcre2"
@@ -212,7 +215,7 @@ sure both macros are undefined; an emulation function will then be used. */
#define PACKAGE_URL ""
/* Define to the version of this package. */
-#define PACKAGE_VERSION "10.21"
+#define PACKAGE_VERSION "10.22-RC1"
/* The value of PARENS_NEST_LIMIT specifies the maximum depth of nested
parentheses (of any kind) in a pattern. This limits the amount of system
@@ -271,6 +274,9 @@ sure both macros are undefined; an emulation function will then be used. */
is able to handle .gz files. */
/* #undef SUPPORT_LIBZ */
+/* Define to any value to enable callout script support in pcre2grep. */
+/* #undef SUPPORT_PCRE2GREP_CALLOUT */
+
/* Define to any value to enable JIT support in pcre2grep. */
/* #undef SUPPORT_PCRE2GREP_JIT */
@@ -293,7 +299,7 @@ sure both macros are undefined; an emulation function will then be used. */
/* #undef SUPPORT_VALGRIND */
/* Version number of package */
-#define VERSION "10.21"
+#define VERSION "10.22-RC1"
/* Define to empty if `const' does not conform to ANSI C. */
/* #undef const */
diff --git a/src/pcre2.h b/src/pcre2.h
index 681d7c7..ab7d803 100644
--- a/src/pcre2.h
+++ b/src/pcre2.h
@@ -155,7 +155,7 @@ through to pcre2_match(). */
#define PCRE2_SUBSTITUTE_UNKNOWN_UNSET 0x00000800u
#define PCRE2_SUBSTITUTE_OVERFLOW_LENGTH 0x00001000u
-/* A further option for pcre2_match(), not allowed for pcre2_dfa_match(),
+/* A further option for pcre2_match(), not allowed for pcre2_dfa_match(),
ignored for pcre2_jit_match(). */
#define PCRE2_NO_JIT 0x00002000u
diff --git a/src/pcre2.h.generic b/src/pcre2.h.generic
index 7f9ba4f..ab7d803 100644
--- a/src/pcre2.h.generic
+++ b/src/pcre2.h.generic
@@ -42,9 +42,9 @@ POSSIBILITY OF SUCH DAMAGE.
/* The current PCRE version information. */
#define PCRE2_MAJOR 10
-#define PCRE2_MINOR 21
-#define PCRE2_PRERELEASE
-#define PCRE2_DATE 2016-01-12
+#define PCRE2_MINOR 22
+#define PCRE2_PRERELEASE -RC1
+#define PCRE2_DATE 2016-06-29
/* When an application links to a PCRE DLL in Windows, the symbols that are
imported have to be identified as such. When building PCRE2, the appropriate
@@ -146,7 +146,8 @@ sanity checks). */
#define PCRE2_DFA_RESTART 0x00000040u
#define PCRE2_DFA_SHORTEST 0x00000080u
-/* These are additional options for pcre2_substitute(). */
+/* These are additional options for pcre2_substitute(), which passes any others
+through to pcre2_match(). */
#define PCRE2_SUBSTITUTE_GLOBAL 0x00000100u
#define PCRE2_SUBSTITUTE_EXTENDED 0x00000200u
@@ -154,6 +155,11 @@ sanity checks). */
#define PCRE2_SUBSTITUTE_UNKNOWN_UNSET 0x00000800u
#define PCRE2_SUBSTITUTE_OVERFLOW_LENGTH 0x00001000u
+/* A further option for pcre2_match(), not allowed for pcre2_dfa_match(),
+ignored for pcre2_jit_match(). */
+
+#define PCRE2_NO_JIT 0x00002000u
+
/* Newline and \R settings, for use in compile contexts. The newline values
must be kept in step with values set in config.h and both sets must all be
greater than zero. */
@@ -245,6 +251,7 @@ numbers must not be changed. */
#define PCRE2_ERROR_BADSUBSTITUTION (-59)
#define PCRE2_ERROR_BADSUBSPATTERN (-60)
#define PCRE2_ERROR_TOOMANYREPLACE (-61)
+#define PCRE2_ERROR_BADSERIALIZEDDATA (-62)
/* Request types for pcre2_pattern_info() */
@@ -436,7 +443,9 @@ PCRE2_EXP_DECL int pcre2_set_recursion_memory_management( \
PCRE2_EXP_DECL \
pcre2_code *pcre2_compile(PCRE2_SPTR, PCRE2_SIZE, uint32_t, \
int *, PCRE2_SIZE *, pcre2_compile_context *); \
-PCRE2_EXP_DECL void pcre2_code_free(pcre2_code *);
+PCRE2_EXP_DECL void pcre2_code_free(pcre2_code *); \
+PCRE2_EXP_DECL \
+ pcre2_code *pcre2_code_copy(const pcre2_code *);
/* Functions that give information about a compiled pattern. */
@@ -585,6 +594,7 @@ pcre2_compile are called by application code. */
/* Functions: the complete list in alphabetical order */
#define pcre2_callout_enumerate PCRE2_SUFFIX(pcre2_callout_enumerate_)
+#define pcre2_code_copy PCRE2_SUFFIX(pcre2_code_copy_)
#define pcre2_code_free PCRE2_SUFFIX(pcre2_code_free_)
#define pcre2_compile PCRE2_SUFFIX(pcre2_compile_)
#define pcre2_compile_context_copy PCRE2_SUFFIX(pcre2_compile_context_copy_)
diff --git a/src/pcre2.h.in b/src/pcre2.h.in
index 51d5428..e1d944d 100644
--- a/src/pcre2.h.in
+++ b/src/pcre2.h.in
@@ -155,7 +155,7 @@ through to pcre2_match(). */
#define PCRE2_SUBSTITUTE_UNKNOWN_UNSET 0x00000800u
#define PCRE2_SUBSTITUTE_OVERFLOW_LENGTH 0x00001000u
-/* A further option for pcre2_match(), not allowed for pcre2_dfa_match(),
+/* A further option for pcre2_match(), not allowed for pcre2_dfa_match(),
ignored for pcre2_jit_match(). */
#define PCRE2_NO_JIT 0x00002000u
diff --git a/src/pcre2_compile.c b/src/pcre2_compile.c
index 2696f44..bb9736c 100644
--- a/src/pcre2_compile.c
+++ b/src/pcre2_compile.c
@@ -149,13 +149,13 @@ have to check them every time. */
#define OFLOW_MAX (INT_MAX - 20)
-/* Macro for setting individual bits in class bitmaps. It took some
-experimenting to figure out how to stop gcc 5.3.0 from warning with
+/* Macro for setting individual bits in class bitmaps. It took some
+experimenting to figure out how to stop gcc 5.3.0 from warning with
-Wconversion. This version gets a warning:
- #define SETBIT(a,b) a[(b)/8] |= (uint8_t)(1 << ((b)&7))
-
-Let's hope the apparently less efficient version isn't actually so bad if the
+ #define SETBIT(a,b) a[(b)/8] |= (uint8_t)(1 << ((b)&7))
+
+Let's hope the apparently less efficient version isn't actually so bad if the
compiler is clever with identical subexpressions. */
#define SETBIT(a,b) a[(b)/8] = (uint8_t)(a[(b)/8] | (1 << ((b)&7)))
@@ -733,7 +733,7 @@ static const uint8_t opcode_possessify[] = {
* Copy compiled code *
*************************************************/
-/* Compiled JIT code cannot be copied, so the new compiled block has no
+/* Compiled JIT code cannot be copied, so the new compiled block has no
associated JIT data. */
PCRE2_EXP_DEFN pcre2_code * PCRE2_CALL_CONVENTION
@@ -748,14 +748,14 @@ if (newcode == NULL) return NULL;
memcpy(newcode, code, code->blocksize);
newcode->executable_jit = NULL;
-/* If the code is one that has been deserialized, increment the reference count
+/* If the code is one that has been deserialized, increment the reference count
in the decoded tables. */
if ((code->flags & PCRE2_DEREF_TABLES) != 0)
{
ref_count = (PCRE2_SIZE *)(code->tables + tables_length);
(*ref_count)++;
- }
+ }
return newcode;
}
@@ -881,7 +881,7 @@ Returns: if non-negative, the fixed length,
or -2 if there is no fixed length,
or -3 if \C was encountered (in UTF mode only)
or -4 if length is too long
- or -5 if regex is too complicated
+ or -5 if regex is too complicated
or -6 if an unknown opcode was encountered (internal error)
*/
@@ -1117,7 +1117,7 @@ for (;;)
cc++;
break;
- /* The single-byte matcher isn't allowed. This only happens in UTF-8 or
+ /* The single-byte matcher isn't allowed. This only happens in UTF-8 or
UTF-16 mode; otherwise \C is coded as OP_ALLANY. */
case OP_ANYBYTE:
@@ -3515,7 +3515,7 @@ for (; ptr < cb->end_pattern; ptr++)
case CHAR_U:
break;
- default:
+ default:
errorcode = ERR11;
ptr--; /* Correct the offset */
goto FAILED;
@@ -3810,7 +3810,7 @@ if (nest_depth == 0)
return 0;
}
-/* We give a special error for a missing closing parentheses after (?# because
+/* We give a special error for a missing closing parentheses after (?# because
it might otherwise be hard to see where the missing character is. */
errorcode = (skiptoket == CHAR_NUMBER_SIGN)? ERR18 : ERR14;
@@ -3963,10 +3963,10 @@ for (;; ptr++)
uint32_t subreqcu, subfirstcu;
int32_t subreqcuflags, subfirstcuflags; /* Must be signed */
PCRE2_UCHAR mcbuffer[8];
-
+
/* Come here to restart the loop. */
-
- REDO_LOOP:
+
+ REDO_LOOP:
/* Get next character in the pattern */
@@ -4249,14 +4249,14 @@ for (;; ptr++)
{
cb->nestptr[0] = ptr + 7;
ptr = sub_start_of_word;
- goto REDO_LOOP;
+ goto REDO_LOOP;
}
if (PRIV(strncmp_c8)(ptr+1, STRING_WEIRD_ENDWORD, 6) == 0)
{
cb->nestptr[0] = ptr + 7;
ptr = sub_end_of_word;
- goto REDO_LOOP;
+ goto REDO_LOOP;
}
/* Handle a real character class. */
@@ -7430,7 +7430,7 @@ for (;; ptr++)
*code++ = (escape == ESC_C)? OP_ALLANY : escape;
#else
*code++ = (!utf && escape == ESC_C)? OP_ALLANY : escape;
-#endif
+#endif
}
}
continue;
diff --git a/src/pcre2_config.c b/src/pcre2_config.c
index 252e47e..e99272f 100644
--- a/src/pcre2_config.c
+++ b/src/pcre2_config.c
@@ -68,7 +68,7 @@ Arguments:
where where to put the information
Returns: 0 if a numerical value is returned
- >= 0 if a string value
+ >= 0 if a string value
PCRE2_ERROR_BADOPTION if "where" not recognized
or JIT target requested when JIT not enabled
*/
diff --git a/src/pcre2_dfa_match.c b/src/pcre2_dfa_match.c
index 2be456a..12b31b1 100644
--- a/src/pcre2_dfa_match.c
+++ b/src/pcre2_dfa_match.c
@@ -2783,7 +2783,7 @@ for (;;)
#endif
if (charcount > 0)
{
- ADD_NEW_DATA(-(state_offset + LINK_SIZE + 1), 0,
+ ADD_NEW_DATA(-(state_offset + LINK_SIZE + 1), 0,
(int)(charcount - 1));
}
else
@@ -3337,7 +3337,7 @@ if (!anchored)
{
first_cu2 = TABLE_GET(first_cu, mb->tables + fcc_offset, first_cu);
#if defined SUPPORT_UNICODE && PCRE2_CODE_UNIT_WIDTH != 8
- if (utf && first_cu > 127)
+ if (utf && first_cu > 127)
first_cu2 = (PCRE2_UCHAR)UCD_OTHERCASE(first_cu);
#endif
}
diff --git a/src/pcre2grep.c b/src/pcre2grep.c
index 2079faa..49747c0 100644
--- a/src/pcre2grep.c
+++ b/src/pcre2grep.c
@@ -1977,7 +1977,7 @@ while (ptr < endptr)
match = match_patterns(matchptr, length, options, startoffset, &mrc);
options = PCRE2_NOTEMPTY;
-
+
/* If it's a match or a not-match (as required), do what's wanted. */
if (match != invert)
@@ -2794,7 +2794,7 @@ if ((popts & PO_FIXED_STRINGS) != 0)
}
sprintf((char *)buffer, "%s%.*s%s", prefix[popts], patlen, ps, suffix[popts]);
-p->compiled = pcre2_compile(buffer, PCRE2_ZERO_TERMINATED, options, &errcode,
+p->compiled = pcre2_compile(buffer, PCRE2_ZERO_TERMINATED, options, &errcode,
&erroffset, compile_context);
/* Handle successful compile */