Added support for (CMake) Unity Builds. (#94)

This commit is contained in:
pkeir 2022-04-24 16:37:37 +01:00 committed by GitHub
parent c630e868ca
commit a13d7d4340
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 18 additions and 6 deletions

View File

@ -10620,4 +10620,8 @@ re = NULL;
goto EXIT; goto EXIT;
} }
#undef NLBLOCK /* Block containing newline information */
#undef PSSTART /* Field containing processed string start */
#undef PSEND /* Field containing processed string end */
/* End of pcre2_compile.c */ /* End of pcre2_compile.c */

View File

@ -67,7 +67,7 @@ POSSIBILITY OF SUCH DAMAGE.
/* States for range and POSIX processing */ /* States for range and POSIX processing */
enum { RANGE_NOT_STARTED, RANGE_STARTING, RANGE_STARTED }; enum { RANGE_NOT_STARTED, RANGE_STARTING, RANGE_ACTIVE };
enum { POSIX_START_REGEX, POSIX_ANCHORED, POSIX_NOT_BRACKET, enum { POSIX_START_REGEX, POSIX_ANCHORED, POSIX_NOT_BRACKET,
POSIX_CLASS_NOT_STARTED, POSIX_CLASS_STARTING, POSIX_CLASS_STARTED }; POSIX_CLASS_NOT_STARTED, POSIX_CLASS_STARTING, POSIX_CLASS_STARTED };

View File

@ -350,7 +350,7 @@ Returns: the return from the callout
*/ */
static int static int
do_callout(PCRE2_SPTR code, PCRE2_SIZE *offsets, PCRE2_SPTR current_subject, do_callout_dfa(PCRE2_SPTR code, PCRE2_SIZE *offsets, PCRE2_SPTR current_subject,
PCRE2_SPTR ptr, dfa_match_block *mb, PCRE2_SIZE extracode, PCRE2_SPTR ptr, dfa_match_block *mb, PCRE2_SIZE extracode,
PCRE2_SIZE *lengthptr) PCRE2_SIZE *lengthptr)
{ {
@ -2799,7 +2799,7 @@ for (;;)
|| code[LINK_SIZE + 1] == OP_CALLOUT_STR) || code[LINK_SIZE + 1] == OP_CALLOUT_STR)
{ {
PCRE2_SIZE callout_length; PCRE2_SIZE callout_length;
rrc = do_callout(code, offsets, current_subject, ptr, mb, rrc = do_callout_dfa(code, offsets, current_subject, ptr, mb,
1 + LINK_SIZE, &callout_length); 1 + LINK_SIZE, &callout_length);
if (rrc < 0) return rrc; /* Abandon */ if (rrc < 0) return rrc; /* Abandon */
if (rrc > 0) break; /* Fail this thread */ if (rrc > 0) break; /* Fail this thread */
@ -3196,7 +3196,7 @@ for (;;)
case OP_CALLOUT_STR: case OP_CALLOUT_STR:
{ {
PCRE2_SIZE callout_length; PCRE2_SIZE callout_length;
rrc = do_callout(code, offsets, current_subject, ptr, mb, 0, rrc = do_callout_dfa(code, offsets, current_subject, ptr, mb, 0,
&callout_length); &callout_length);
if (rrc < 0) return rrc; /* Abandon */ if (rrc < 0) return rrc; /* Abandon */
if (rrc == 0) if (rrc == 0)
@ -4057,4 +4057,8 @@ while (rws->next != NULL)
return rc; return rc;
} }
#undef NLBLOCK /* Block containing newline information */
#undef PSSTART /* Field containing processed string start */
#undef PSEND /* Field containing processed string end */
/* End of pcre2_dfa_match.c */ /* End of pcre2_dfa_match.c */

View File

@ -9689,7 +9689,7 @@ BACKTRACK_AS(recurse_backtrack)->matchingpath = LABEL();
return cc + 1 + LINK_SIZE; return cc + 1 + LINK_SIZE;
} }
static sljit_s32 SLJIT_FUNC do_callout(struct jit_arguments *arguments, pcre2_callout_block *callout_block, PCRE2_SPTR *jit_ovector) static sljit_s32 SLJIT_FUNC do_callout_jit(struct jit_arguments *arguments, pcre2_callout_block *callout_block, PCRE2_SPTR *jit_ovector)
{ {
PCRE2_SPTR begin; PCRE2_SPTR begin;
PCRE2_SIZE *ovector; PCRE2_SIZE *ovector;
@ -9806,7 +9806,7 @@ OP1(SLJIT_MOV, SLJIT_MEM1(SLJIT_SP), LOCALS0, STR_PTR, 0);
/* SLJIT_R0 = arguments */ /* SLJIT_R0 = arguments */
OP1(SLJIT_MOV, SLJIT_R1, 0, STACK_TOP, 0); OP1(SLJIT_MOV, SLJIT_R1, 0, STACK_TOP, 0);
GET_LOCAL_BASE(SLJIT_R2, 0, OVECTOR_START); GET_LOCAL_BASE(SLJIT_R2, 0, OVECTOR_START);
sljit_emit_icall(compiler, SLJIT_CALL, SLJIT_ARGS3(32, W, W, W), SLJIT_IMM, SLJIT_FUNC_ADDR(do_callout)); sljit_emit_icall(compiler, SLJIT_CALL, SLJIT_ARGS3(32, W, W, W), SLJIT_IMM, SLJIT_FUNC_ADDR(do_callout_jit));
OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_SP), LOCALS0); OP1(SLJIT_MOV, STR_PTR, 0, SLJIT_MEM1(SLJIT_SP), LOCALS0);
free_stack(common, callout_arg_size); free_stack(common, callout_arg_size);

View File

@ -7533,4 +7533,8 @@ else match_data->rc = PCRE2_ERROR_NOMATCH;
return match_data->rc; return match_data->rc;
} }
#undef NLBLOCK /* Block containing newline information */
#undef PSSTART /* Field containing processed string start */
#undef PSEND /* Field containing processed string end */
/* End of pcre2_match.c */ /* End of pcre2_match.c */