summaryrefslogtreecommitdiff
path: root/ext/pcre/pcre2lib/pcre2_internal.h
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2020-06-30 18:24:48 +0200
committerNikita Popov <nikita.ppv@gmail.com>2020-06-30 18:24:48 +0200
commite2a407c2fe788e685055e81d672c8cc6cd7ceaa5 (patch)
treeeff567b3b57d2ec369e6a8f8615d754a2655cac0 /ext/pcre/pcre2lib/pcre2_internal.h
parentaf4ff75c989374d2f850ae397d62d5a537532c40 (diff)
downloadphp-git-e2a407c2fe788e685055e81d672c8cc6cd7ceaa5.tar.gz
Revert "Update to PCRE2 10.35"
This reverts commit b419f96c626d1f9cbbba42698e947e32a0af9c4f. This breaks the GCC build with -fcf-protection (default on Ubuntu at least).
Diffstat (limited to 'ext/pcre/pcre2lib/pcre2_internal.h')
-rw-r--r--ext/pcre/pcre2lib/pcre2_internal.h21
1 files changed, 6 insertions, 15 deletions
diff --git a/ext/pcre/pcre2lib/pcre2_internal.h b/ext/pcre/pcre2lib/pcre2_internal.h
index d8fad1e93b..fe8ffe5c80 100644
--- a/ext/pcre/pcre2lib/pcre2_internal.h
+++ b/ext/pcre/pcre2lib/pcre2_internal.h
@@ -7,7 +7,7 @@ and semantics are as close as possible to those of the Perl 5 language.
Written by Philip Hazel
Original API code Copyright (c) 1997-2012 University of Cambridge
- New API code Copyright (c) 2016-2020 University of Cambridge
+ New API code Copyright (c) 2016-2019 University of Cambridge
-----------------------------------------------------------------------------
Redistribution and use in source and binary forms, with or without
@@ -76,17 +76,6 @@ typedef int BOOL;
#include <valgrind/memcheck.h>
#endif
-/* -ftrivial-auto-var-init support supports initializing all local variables
-to avoid some classes of bug, but this can cause an unacceptable slowdown
-for large on-stack arrays in hot functions. This macro lets us annotate
-such arrays. */
-
-#ifdef HAVE_ATTRIBUTE_UNINITIALIZED
-#define PCRE2_KEEP_UNINITIALIZED __attribute__((uninitialized))
-#else
-#define PCRE2_KEEP_UNINITIALIZED
-#endif
-
/* Older versions of MSVC lack snprintf(). This define allows for
warning/error-free compilation and testing with MSVC compilers back to at least
MSVC 10/2010. Except for VC6 (which is missing some fundamentals and fails). */
@@ -590,7 +579,7 @@ total length of the tables. */
#define fcc_offset 256 /* Flip case */
#define cbits_offset 512 /* Character classes */
#define ctypes_offset (cbits_offset + cbit_length) /* Character types */
-#define TABLES_LENGTH (ctypes_offset + 256)
+#define tables_length (ctypes_offset + 256)
/* -------------------- Character and string names ------------------------ */
@@ -1770,11 +1759,13 @@ typedef struct pcre2_memctl {
/* Structure for building a chain of open capturing subpatterns during
compiling, so that instructions to close them can be compiled when (*ACCEPT) is
-encountered. */
+encountered. This is also used to identify subpatterns that contain recursive
+back references to themselves, so that they can be made atomic. */
typedef struct open_capitem {
struct open_capitem *next; /* Chain link */
uint16_t number; /* Capture number */
+ uint16_t flag; /* Set TRUE if recursive back ref */
uint16_t assert_depth; /* Assertion depth when opened */
} open_capitem;
@@ -1963,7 +1954,7 @@ is available. */
#define _pcre2_was_newline PCRE2_SUFFIX(_pcre2_was_newline_)
#define _pcre2_xclass PCRE2_SUFFIX(_pcre2_xclass_)
-extern int _pcre2_auto_possessify(PCRE2_UCHAR *,
+extern int _pcre2_auto_possessify(PCRE2_UCHAR *, BOOL,
const compile_block *);
extern int _pcre2_check_escape(PCRE2_SPTR *, PCRE2_SPTR, uint32_t *,
int *, uint32_t, uint32_t, BOOL, compile_block *);