Lines Matching refs:c

266 #define PFETCH(c)  do { \  argument
267 c = ONIGENC_MBC_TO_CODE(enc, p, end); \
273 #define PPEEK_IS(c) (PPEEK == (OnigCodePoint )c) argument
372 int c; in strend_cmp() local
380 c = (int )*p - (int )*q; in strend_cmp()
381 if (c != 0) return c; in strend_cmp()
1427 node_str_cat_char(Node* node, UChar c) in node_str_cat_char() argument
1431 s[0] = c; in node_str_cat_char()
1501 node_new_str_char(UChar c) in node_new_str_char() argument
1505 p[0] = c; in node_new_str_char()
1558 OnigCodePoint c; in onig_scan_unsigned_number() local
1564 PFETCH(c); in onig_scan_unsigned_number()
1565 if (ONIGENC_IS_CODE_DIGIT(enc, c)) { in onig_scan_unsigned_number()
1566 val = (unsigned int )DIGITVAL(c); in onig_scan_unsigned_number()
1585 OnigCodePoint c; in scan_unsigned_hexadecimal_number() local
1592 PFETCH(c); in scan_unsigned_hexadecimal_number()
1593 if (ONIGENC_IS_CODE_XDIGIT(enc, c)) { in scan_unsigned_hexadecimal_number()
1594 val = (unsigned int )XDIGITVAL(enc,c); in scan_unsigned_hexadecimal_number()
1598 num = (num << 4) + XDIGITVAL(enc,c); in scan_unsigned_hexadecimal_number()
1613 OnigCodePoint c; in scan_unsigned_octal_number() local
1620 PFETCH(c); in scan_unsigned_octal_number()
1621 if (ONIGENC_IS_CODE_DIGIT(enc, c) && c < '8') { in scan_unsigned_octal_number()
1622 val = ODIGITVAL(c); in scan_unsigned_octal_number()
2065 conv_backslash_value(int c, ScanEnv* env) in conv_backslash_value() argument
2068 switch (c) { in conv_backslash_value()
2085 return c; in conv_backslash_value()
2169 QuantifierNode *p, *c; in onig_reduce_nested_quantifier() local
2172 c = &(NQUANTIFIER(cnode)); in onig_reduce_nested_quantifier()
2174 cnum = popular_quantifier_num(c); in onig_reduce_nested_quantifier()
2178 *p = *c; in onig_reduce_nested_quantifier()
2181 p->target = c->target; in onig_reduce_nested_quantifier()
2185 p->target = c->target; in onig_reduce_nested_quantifier()
2189 p->target = c->target; in onig_reduce_nested_quantifier()
2195 c->lower = 1; c->upper = REPEAT_INFINITE; c->greedy = 1; in onig_reduce_nested_quantifier()
2201 c->lower = 1; c->upper = REPEAT_INFINITE; c->greedy = 0; in onig_reduce_nested_quantifier()
2210 c->target = NULL_NODE; in onig_reduce_nested_quantifier()
2250 int c; member
2286 OnigCodePoint c; in fetch_range_quantifier() local
2301 c = PPEEK; in fetch_range_quantifier()
2302 if (c == ')' || c == '(' || c == '|') { in fetch_range_quantifier()
2323 PFETCH(c); in fetch_range_quantifier()
2324 if (c == ',') { in fetch_range_quantifier()
2347 PFETCH(c); in fetch_range_quantifier()
2349 if (c != MC_ESC(enc)) goto invalid; in fetch_range_quantifier()
2350 PFETCH(c); in fetch_range_quantifier()
2352 if (c != '}') goto invalid; in fetch_range_quantifier()
2376 OnigCodePoint c; in fetch_escaped_value() local
2383 PFETCH(c); in fetch_escaped_value()
2384 switch (c) { in fetch_escaped_value()
2388 PFETCH(c); in fetch_escaped_value()
2389 if (c != '-') return ONIGERR_META_CODE_SYNTAX; in fetch_escaped_value()
2391 PFETCH(c); in fetch_escaped_value()
2392 if (c == MC_ESC(enc)) { in fetch_escaped_value()
2395 c = (OnigCodePoint )v; in fetch_escaped_value()
2397 c = ((c & 0xff) | 0x80); in fetch_escaped_value()
2406 PFETCH(c); in fetch_escaped_value()
2407 if (c != '-') return ONIGERR_CONTROL_CODE_SYNTAX; in fetch_escaped_value()
2417 PFETCH(c); in fetch_escaped_value()
2418 if (c == '?') { in fetch_escaped_value()
2419 c = 0177; in fetch_escaped_value()
2422 if (c == MC_ESC(enc)) { in fetch_escaped_value()
2425 c = (OnigCodePoint )v; in fetch_escaped_value()
2427 c &= 0x9f; in fetch_escaped_value()
2436 c = conv_backslash_value(c, env); in fetch_escaped_value()
2442 return c; in fetch_escaped_value()
2457 OnigCodePoint c = 0; in fetch_name_with_level() local
2470 PFETCH(c); in fetch_name_with_level()
2471 first_code = c; in fetch_name_with_level()
2472 if (c == '>') in fetch_name_with_level()
2475 if (!ONIGENC_IS_CODE_WORD(enc, c)) { in fetch_name_with_level()
2482 PFETCH(c); in fetch_name_with_level()
2483 if (c == '>' || c == ')' || c == '+' || c == '-') break; in fetch_name_with_level()
2485 if (!ONIGENC_IS_CODE_WORD(enc, c)) { in fetch_name_with_level()
2490 if (c != '>') { in fetch_name_with_level()
2491 if (c == '+' || c == '-') { in fetch_name_with_level()
2493 int flag = (c == '-' ? -1 : 1); in fetch_name_with_level()
2495 PFETCH(c); in fetch_name_with_level()
2496 if (! ONIGENC_IS_CODE_DIGIT(enc, c)) goto err; in fetch_name_with_level()
2503 PFETCH(c); in fetch_name_with_level()
2504 if (c == '>') in fetch_name_with_level()
2539 OnigCodePoint c = 0; in fetch_name() local
2553 PFETCH(c); in fetch_name()
2554 first_code = c; in fetch_name()
2555 if (c == '>') in fetch_name()
2558 if (ONIGENC_IS_CODE_DIGIT(enc, c)) { in fetch_name()
2565 else if (!ONIGENC_IS_CODE_WORD(enc, c)) { in fetch_name()
2572 PFETCH(c); in fetch_name()
2573 if (c == '>' || c == ')') break; in fetch_name()
2576 if (! ONIGENC_IS_CODE_DIGIT(enc, c)) { in fetch_name()
2577 if (!ONIGENC_IS_CODE_WORD(enc, c)) in fetch_name()
2584 if (!ONIGENC_IS_CODE_WORD(enc, c)) { in fetch_name()
2590 if (c != '>') { in fetch_name()
2615 OnigCodePoint c = 0; in fetch_name() local
2627 PFETCH(c); in fetch_name()
2628 if (c == '>' || c == ')') break; in fetch_name()
2629 if (! ONIGENC_IS_CODE_DIGIT(enc, c)) in fetch_name()
2632 if (c != '>') { in fetch_name()
2651 CC_ESC_WARN(ScanEnv* env, UChar *c) in CC_ESC_WARN() argument
2660 (UChar* )"character class has '%s' without escape", c); in CC_ESC_WARN()
2666 CCEND_ESC_WARN(ScanEnv* env, UChar* c) in CCEND_ESC_WARN() argument
2674 (UChar* )"regular expression has '%s' without escape", c); in CCEND_ESC_WARN()
2750 OnigCodePoint c, c2; in fetch_token_in_cc() local
2762 PFETCH(c); in fetch_token_in_cc()
2765 tok->u.c = c; in fetch_token_in_cc()
2768 if (c == ']') { in fetch_token_in_cc()
2771 else if (c == '-') { in fetch_token_in_cc()
2774 else if (c == MC_ESC(enc)) { in fetch_token_in_cc()
2780 PFETCH(c); in fetch_token_in_cc()
2782 tok->u.c = c; in fetch_token_in_cc()
2783 switch (c) { in fetch_token_in_cc()
2826 tok->u.prop.not = (c == 'P' ? 1 : 0); in fetch_token_in_cc()
2872 tok->u.c = num; in fetch_token_in_cc()
2904 tok->u.c = num; in fetch_token_in_cc()
2912 if (tok->u.c != num) { in fetch_token_in_cc()
2919 else if (c == '[') { in fetch_token_in_cc()
2943 else if (c == '&') { in fetch_token_in_cc()
2960 OnigCodePoint c; in fetch_token() local
2977 PFETCH(c); in fetch_token()
2978 if (IS_MC_ESC_CODE(c, enc, syn)) { in fetch_token()
2982 PFETCH(c); in fetch_token()
2984 tok->u.c = c; in fetch_token()
2986 switch (c) { in fetch_token()
3011 PFETCH(c); in fetch_token()
3022 PFETCH(c); in fetch_token()
3203 tok->u.c = num; in fetch_token()
3250 if (c == '8' || c == '9') { in fetch_token()
3261 num = scan_unsigned_octal_number(&p, end, (c == '0' ? 2:3), enc); in fetch_token()
3268 tok->u.c = num; in fetch_token()
3270 else if (c != '0') { in fetch_token()
3278 PFETCH(c); in fetch_token()
3279 if (c == '<') { in fetch_token()
3330 PFETCH(c); in fetch_token()
3331 if (c == '<') { in fetch_token()
3360 tok->u.prop.not = (c == 'P' ? 1 : 0); in fetch_token()
3363 PFETCH(c); in fetch_token()
3364 if (c == '^') { in fetch_token()
3378 if (tok->u.c != num) { in fetch_token()
3389 tok->u.c = c; in fetch_token()
3393 if ((c != ONIG_INEFFECTIVE_META_CHAR) && in fetch_token()
3395 if (c == MC_ANYCHAR(enc)) in fetch_token()
3397 else if (c == MC_ANYTIME(enc)) in fetch_token()
3399 else if (c == MC_ZERO_OR_ONE_TIME(enc)) in fetch_token()
3401 else if (c == MC_ONE_OR_MORE_TIME(enc)) in fetch_token()
3403 else if (c == MC_ANYCHAR_ANYTIME(enc)) { in fetch_token()
3410 switch (c) { in fetch_token()
3476 PFETCH(c); in fetch_token()
3479 PFETCH(c); in fetch_token()
3480 if (c == MC_ESC(enc)) { in fetch_token()
3481 if (!PEND) PFETCH(c); in fetch_token()
3484 if (c == ')') break; in fetch_token()
3528 PFETCH(c); in fetch_token()
3529 if (ONIGENC_IS_CODE_NEWLINE(enc, c)) in fetch_token()
3620 int c, r; in add_ctype_to_cc() local
3646 for (c = 0; c < SINGLE_BYTE_SIZE; c++) { in add_ctype_to_cc()
3647 if (! ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) in add_ctype_to_cc()
3648 BITSET_SET_BIT(cc->bs, c); in add_ctype_to_cc()
3653 for (c = 0; c < SINGLE_BYTE_SIZE; c++) { in add_ctype_to_cc()
3654 if (ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) in add_ctype_to_cc()
3655 BITSET_SET_BIT(cc->bs, c); in add_ctype_to_cc()
3663 for (c = 0; c < SINGLE_BYTE_SIZE; c++) { in add_ctype_to_cc()
3664 if (! ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) in add_ctype_to_cc()
3665 BITSET_SET_BIT(cc->bs, c); in add_ctype_to_cc()
3669 for (c = 0; c < SINGLE_BYTE_SIZE; c++) { in add_ctype_to_cc()
3670 if (ONIGENC_IS_CODE_CTYPE(enc, (OnigCodePoint )c, ctype)) in add_ctype_to_cc()
3671 BITSET_SET_BIT(cc->bs, c); in add_ctype_to_cc()
3679 for (c = 0; c < SINGLE_BYTE_SIZE; c++) { in add_ctype_to_cc()
3680 if (ONIGENC_IS_CODE_SB_WORD(enc, c)) BITSET_SET_BIT(cc->bs, c); in add_ctype_to_cc()
3685 for (c = 0; c < SINGLE_BYTE_SIZE; c++) { in add_ctype_to_cc()
3686 if ((ONIGENC_CODE_TO_MBCLEN(enc, c) > 0) /* 0: invalid code point */ in add_ctype_to_cc()
3687 && ! ONIGENC_IS_CODE_WORD(enc, c)) in add_ctype_to_cc()
3688 BITSET_SET_BIT(cc->bs, c); in add_ctype_to_cc()
3777 OnigCodePoint c; in parse_posix_bracket() local
3808 c = 0; in parse_posix_bracket()
3810 while (!PEND && ((c = PPEEK) != ':') && c != ']') { in parse_posix_bracket()
3814 if (c == ':' && ! PEND) { in parse_posix_bracket()
3817 PFETCH(c); in parse_posix_bracket()
3818 if (c == ']') in parse_posix_bracket()
3863 OnigCodePoint c; in fetch_char_property_to_ctype() local
3871 c = PPEEK; in fetch_char_property_to_ctype()
3872 if (c == 'I') { in fetch_char_property_to_ctype()
3875 c = PPEEK; in fetch_char_property_to_ctype()
3876 if (c == 's') in fetch_char_property_to_ctype()
3888 PFETCH(c); in fetch_char_property_to_ctype()
3889 if (c == '}') { in fetch_char_property_to_ctype()
3896 else if (c == '(' || c == ')' || c == '{' || c == '|') in fetch_char_property_to_ctype()
4038 code_exist_check(OnigCodePoint c, UChar* from, UChar* end, int ignore_escaped, in code_exist_check() argument
4053 if (code == c) return 1; in code_exist_check()
4078 if (r == TK_CHAR && tok->u.c == '^' && tok->escaped == 0) { in parse_char_class()
4107 len = ONIGENC_CODE_TO_MBCLEN(env->enc, tok->u.c); in parse_char_class()
4115 v = (OnigCodePoint )tok->u.c; in parse_char_class()
4128 buf[0] = tok->u.c; in parse_char_class()
4136 buf[i] = tok->u.c; in parse_char_class()
4167 v = (OnigCodePoint )tok->u.c; in parse_char_class()
4197 v = (OnigCodePoint )tok->u.c; in parse_char_class()
4248 v = (OnigCodePoint )tok->u.c; in parse_char_class()
4399 OnigCodePoint c; in parse_effect() local
4412 PFETCH(c); in parse_effect()
4413 switch (c) { in parse_effect()
4435 PFETCH(c); in parse_effect()
4436 if (c == '=') in parse_effect()
4438 else if (c == '!') in parse_effect()
4476 PFETCH(c); in parse_effect()
4477 if (c == '<') { in parse_effect()
4511 switch (c) { in parse_effect()
4546 if (c == ')') { in parse_effect()
4552 else if (c == ':') { in parse_effect()
4569 PFETCH(c); in parse_effect()
4856 *np = node_new_str_char((UChar )tok->u.c); in parse_exp()
4883 r = node_str_cat_char(*np, (UChar )tok->u.c); in parse_exp()