Home | History | Annotate | Download | only in src

Lines Matching refs:code

9      Original API code Copyright (c) 1997-2012 University of Cambridge
10 New API code Copyright (c) 2016 University of Cambridge
16 * Redistributions of source code must retain the above copyright notice,
65 zero because property types are handled separately in the code. The last four
162 because they can all use the same code. For more details see the comment where
289 /* Checks whether the code points to an opcode that can take part in auto-
293 code points to start of expression
302 Returns: points to the start of the next opcode if *code is accepted
303 NULL if *code is not accepted
307 get_chr_property_list(PCRE2_SPTR code, BOOL utf, const uint8_t *fcc,
310 PCRE2_UCHAR c = *code;
324 code++;
332 code += IMM2_SIZE;
356 list[0] = *code;
357 code++;
383 return code;
387 GETCHARINCTEST(chr, code);
390 return code;
395 GETCHARINCTEST(chr, code);
415 return code;
420 if (code[0] != PT_CLIST)
422 list[2] = code[0];
423 list[3] = code[1];
424 return code + 2;
429 clist_src = PRIV(ucd_caseless_sets) + code[1];
431 code += 2;
438 list[2] = code[0];
439 list[3] = code[1];
440 return code;
450 return code;
458 end = code + GET(code, 0) - 1;
461 end = code + 32 / sizeof(PCRE2_UCHAR);
488 list[2] = (uint32_t)(end - code);
504 code points to the byte code
515 compare_opcodes(PCRE2_SPTR code, BOOL utf, const compile_block *cb,
542 /* All operations move the code pointer forward.
545 c = *code;
551 code += PRIV(OP_lengths)[c];
557 code += GET(code, 1 + 2*LINK_SIZE);
563 do code += GET(code, 1); while (*code == OP_ALT);
564 c = *code;
584 switch(*(code - GET(code, 1)))
599 code += PRIV(OP_lengths)[c];
606 next_code = code + GET(code, 1);
607 code += PRIV(OP_lengths)[c];
611 if (!compare_opcodes(code, utf, cb, base_list, base_end, rec_limit))
613 code = next_code + 1 + LINK_SIZE;
623 next_code = code + 1;
635 code += PRIV(OP_lengths)[c];
644 code = get_chr_property_list(code, utf, cb->fcc, list);
645 if (code == NULL) return FALSE; /* Unsupported */
681 set1 = (uint8_t *)(code - list[2]);
691 ((list_ptr == list ? code : base_end) - list_ptr[2]);
696 xclass_flags = (list_ptr == list ? code : base_end) - list_ptr[2] + LINK_SIZE;
810 /* This code is logically tricky. Think hard before fiddling with it.
814 others means they can all use the same code below.
1013 ((list_ptr == list ? code : base_end) - list_ptr[2]);
1019 if (PRIV(xclass)(chr, (list_ptr == list ? code : base_end) -
1053 code points to start of the byte code
1062 PRIV(auto_possessify)(PCRE2_UCHAR *code, BOOL utf, const compile_block *cb)
1072 c = *code;
1080 get_chr_property_list(code, utf, cb->fcc, list) : NULL;
1089 *code += OP_POSSTAR - OP_STAR;
1093 *code += OP_POSSTAR - OP_MINSTAR;
1097 *code += OP_POSPLUS - OP_PLUS;
1101 *code += OP_POSPLUS - OP_MINPLUS;
1105 *code += OP_POSQUERY - OP_QUERY;
1109 *code += OP_POSQUERY - OP_MINQUERY;
1113 *code += OP_POSUPTO - OP_UPTO;
1117 *code += OP_POSUPTO - OP_MINUPTO;
1121 c = *code;
1127 repeat_opcode = code + GET(code, 1);
1130 repeat_opcode = code + 1 + (32 / sizeof(PCRE2_UCHAR));
1136 end = get_chr_property_list(code, utf, cb->fcc, list);
1167 c = *code;
1184 if (code[1] == OP_PROP || code[1] == OP_NOTPROP) code += 2;
1191 if (code[1 + IMM2_SIZE] == OP_PROP || code[1 + IMM2_SIZE] == OP_NOTPROP)
1192 code += 2;
1196 code += GET(code, 1 + 2*LINK_SIZE);
1201 code += GET(code, 1);
1209 code += code[1];
1215 code += PRIV(OP_lengths)[c];
1219 we have to arrange to skip the extra code units. */
1280 if (HAS_EXTRALEN(code[-1])) code += GET_EXTRALEN(code[-1]);