@@ -42,40 +42,37 @@ POSSIBILITY OF SUCH DAMAGE.
4242/* The current PCRE version information. */
4343
4444#define PCRE2_MAJOR 10
45- #define PCRE2_MINOR 46
45+ #define PCRE2_MINOR 47
4646#define PCRE2_PRERELEASE
47- #define PCRE2_DATE 2025-08-27
47+ #define PCRE2_DATE 2025-10-21
4848
49- /* When an application links to a PCRE DLL in Windows, the symbols that are
49+ /* When an application links to a PCRE2 DLL in Windows, the symbols that are
5050imported have to be identified as such. When building PCRE2, the appropriate
51- export setting is defined in pcre2_internal.h, which includes this file. So we
52- don't change existing definitions of PCRE2_EXP_DECL. */
51+ export setting is defined in pcre2_internal.h, which includes this file. So, we
52+ don't change existing definitions of PCRE2_EXP_DECL.
5353
54- #if defined(_WIN32 ) && !defined(PCRE2_STATIC )
55- # ifndef PCRE2_EXP_DECL
56- # define PCRE2_EXP_DECL extern __declspec(dllimport)
57- # endif
58- #endif
59-
60- /* By default, we use the standard "extern" declarations. */
54+ By default, we use the standard "extern" declarations. */
6155
6256#ifndef PCRE2_EXP_DECL
63- # ifdef __cplusplus
57+ # if defined(_WIN32 ) && !defined(PCRE2_STATIC )
58+ # define PCRE2_EXP_DECL extern __declspec(dllimport)
59+ # elif defined __cplusplus
6460# define PCRE2_EXP_DECL extern "C"
6561# else
6662# define PCRE2_EXP_DECL extern
6763# endif
6864#endif
6965
7066/* When compiling with the MSVC compiler, it is sometimes necessary to include
71- a "calling convention" before exported function names. (This is secondhand
72- information; I know nothing about MSVC myself). For example, something like
67+ a "calling convention" before exported function names. For example:
7368
7469 void __cdecl function(....)
7570
76- might be needed. In order so make this easy, all the exported functions have
77- PCRE2_CALL_CONVENTION just before their names. It is rarely needed; if not
78- set, we ensure here that it has no effect. */
71+ might be needed. In order to make this easy, all the exported functions have
72+ PCRE2_CALL_CONVENTION just before their names.
73+
74+ PCRE2 normally uses the platform's standard calling convention, so this should
75+ not be set unless you know you need it. */
7976
8077#ifndef PCRE2_CALL_CONVENTION
8178#define PCRE2_CALL_CONVENTION
@@ -343,6 +340,10 @@ pcre2_pattern_convert(). */
343340#define PCRE2_ERROR_PERL_ECLASS_EMPTY_EXPR 214
344341#define PCRE2_ERROR_PERL_ECLASS_MISSING_CLOSE 215
345342#define PCRE2_ERROR_PERL_ECLASS_UNEXPECTED_CHAR 216
343+ #define PCRE2_ERROR_EXPECTED_CAPTURE_GROUP 217
344+ #define PCRE2_ERROR_MISSING_OPENING_PARENTHESIS 218
345+ #define PCRE2_ERROR_MISSING_NUMBER_TERMINATOR 219
346+ #define PCRE2_ERROR_NULL_ERROROFFSET 220
346347
347348/* "Expected" matching error codes: no match and partial match. */
348349
@@ -432,6 +433,11 @@ released, the numbers must not be changed. */
432433#define PCRE2_ERROR_JIT_UNSUPPORTED (-68)
433434#define PCRE2_ERROR_REPLACECASE (-69)
434435#define PCRE2_ERROR_TOOLARGEREPLACE (-70)
436+ #define PCRE2_ERROR_DIFFSUBSPATTERN (-71)
437+ #define PCRE2_ERROR_DIFFSUBSSUBJECT (-72)
438+ #define PCRE2_ERROR_DIFFSUBSOFFSET (-73)
439+ #define PCRE2_ERROR_DIFFSUBSOPTIONS (-74)
440+ #define PCRE2_ERROR_BAD_BACKSLASH_K (-75)
435441
436442
437443/* Request types for pcre2_pattern_info() */
@@ -484,6 +490,7 @@ released, the numbers must not be changed. */
484490#define PCRE2_CONFIG_NEVER_BACKSLASH_C 13
485491#define PCRE2_CONFIG_COMPILED_WIDTHS 14
486492#define PCRE2_CONFIG_TABLES_LENGTH 15
493+ #define PCRE2_CONFIG_EFFECTIVE_LINKSIZE 16
487494
488495/* Optimization directives for pcre2_set_optimize().
489496For binary compatibility, only add to this list; do not renumber. */
@@ -743,14 +750,14 @@ PCRE2_EXP_DECL pcre2_match_data *PCRE2_CALL_CONVENTION \
743750PCRE2_EXP_DECL pcre2_match_data *PCRE2_CALL_CONVENTION \
744751 pcre2_match_data_create_from_pattern(const pcre2_code *, \
745752 pcre2_general_context *); \
753+ PCRE2_EXP_DECL void PCRE2_CALL_CONVENTION \
754+ pcre2_match_data_free(pcre2_match_data *); \
746755PCRE2_EXP_DECL int PCRE2_CALL_CONVENTION \
747756 pcre2_dfa_match(const pcre2_code *, PCRE2_SPTR, PCRE2_SIZE, PCRE2_SIZE, \
748757 uint32_t, pcre2_match_data *, pcre2_match_context *, int *, PCRE2_SIZE); \
749758PCRE2_EXP_DECL int PCRE2_CALL_CONVENTION \
750759 pcre2_match(const pcre2_code *, PCRE2_SPTR, PCRE2_SIZE, PCRE2_SIZE, \
751760 uint32_t, pcre2_match_data *, pcre2_match_context *); \
752- PCRE2_EXP_DECL void PCRE2_CALL_CONVENTION \
753- pcre2_match_data_free(pcre2_match_data *); \
754761PCRE2_EXP_DECL PCRE2_SPTR PCRE2_CALL_CONVENTION \
755762 pcre2_get_mark(pcre2_match_data *); \
756763PCRE2_EXP_DECL PCRE2_SIZE PCRE2_CALL_CONVENTION \
@@ -762,7 +769,9 @@ PCRE2_EXP_DECL uint32_t PCRE2_CALL_CONVENTION \
762769PCRE2_EXP_DECL PCRE2_SIZE *PCRE2_CALL_CONVENTION \
763770 pcre2_get_ovector_pointer(pcre2_match_data *); \
764771PCRE2_EXP_DECL PCRE2_SIZE PCRE2_CALL_CONVENTION \
765- pcre2_get_startchar(pcre2_match_data *);
772+ pcre2_get_startchar(pcre2_match_data *); \
773+ PCRE2_EXP_DECL int PCRE2_CALL_CONVENTION \
774+ pcre2_next_match(pcre2_match_data *, PCRE2_SIZE *, uint32_t *);
766775
767776
768777/* Convenience functions for handling matched substrings. */
@@ -942,6 +951,7 @@ pcre2_compile are called by application code. */
942951#define pcre2_match_data_create PCRE2_SUFFIX(pcre2_match_data_create_)
943952#define pcre2_match_data_create_from_pattern PCRE2_SUFFIX(pcre2_match_data_create_from_pattern_)
944953#define pcre2_match_data_free PCRE2_SUFFIX(pcre2_match_data_free_)
954+ #define pcre2_next_match PCRE2_SUFFIX(pcre2_next_match_)
945955#define pcre2_pattern_convert PCRE2_SUFFIX(pcre2_pattern_convert_)
946956#define pcre2_pattern_info PCRE2_SUFFIX(pcre2_pattern_info_)
947957#define pcre2_serialize_decode PCRE2_SUFFIX(pcre2_serialize_decode_)
0 commit comments