Lines Matching refs:info

312                     struct regex_info *info) {
347 if (info->flags & SLRE_IGNORE_CASE) {
360 struct regex_info *info) {
369 result = info->flags & SLRE_IGNORE_CASE ?
374 result = match_op((unsigned char *) re + len, (unsigned char *) s, info);
381 static int doh(const char *s, int s_len, struct regex_info *info, int bi);
384 struct regex_info *info, int bi) {
391 step = re[i] == '(' ? info->brackets[bi + 1].len + 2 :
404 int result = bar(re + i, step, s + j, s_len - j, info, bi);
418 if ((n1 = bar(re + i, step, s + j2, s_len - j2, info, bi)) > 0) {
427 s_len - j2, info, bi)) >= 0) {
439 (n2 = bar(re + ni, re_len - ni, s + j, s_len - j, info, bi)) > 0) {
457 n = match_set(re + i + 1, re_len - (i + 2), s + j, info);
464 FAIL_IF(bi >= info->num_brackets, SLRE_INTERNAL_ERROR);
470 n = doh(s + j, s_len - j, info, bi);
474 if ((n = doh(s + j, s_len - (j + j2), info, bi)) >= 0 &&
476 s + j + n, s_len - (j + n), info, bi) >= 0) break;
482 if (info->caps != NULL && n > 0) {
483 info->caps[bi - 1].ptr = s + j;
484 info->caps[bi - 1].len = n;
493 n = match_op((unsigned char *) (re + i), (unsigned char *) (s + j), info);
503 static int doh(const char *s, int s_len, struct regex_info *info, int bi) {
504 const struct bracket_pair *b = &info->brackets[bi];
509 p = i == 0 ? b->ptr : info->branches[b->branches + i - 1].schlong + 1;
512 (int) (info->branches[b->branches + i].schlong - p);
514 result = bar(p, len, s, s_len, info, bi);
521 static int baz(const char *s, int s_len, struct regex_info *info) {
522 int i, result = -1, is_anchored = info->brackets[0].ptr[0] == '^';
525 result = doh(s + i, s_len - i, info, 0);
536 static void setup_branch_points(struct regex_info *info) {
541 for (i = 0; i < info->num_branches; i++) {
542 for (j = i + 1; j < info->num_branches; j++) {
543 if (info->branches[i].bracket_index > info->branches[j].bracket_index) {
544 tmp = info->branches[i];
545 info->branches[i] = info->branches[j];
546 info->branches[j] = tmp;
555 for (i = j = 0; i < info->num_brackets; i++) {
556 info->brackets[i].num_branches = 0;
557 info->brackets[i].branches = j;
558 while (j < info->num_branches && info->branches[j].bracket_index == i) {
559 info->brackets[i].num_branches++;
566 struct regex_info *info) {
570 info->brackets[0].ptr = re;
571 info->brackets[0].len = re_len;
572 info->num_brackets = 1;
579 FAIL_IF(info->num_branches >= (int) ARRAY_SIZE(info->branches),
581 info->branches[info->num_branches].bracket_index =
582 info->brackets[info->num_brackets - 1].len == -1 ?
583 info->num_brackets - 1 : depth;
584 info->branches[info->num_branches].schlong = &re[i];
585 info->num_branches++;
599 FAIL_IF(info->num_brackets >= (int) ARRAY_SIZE(info->brackets),
602 info->brackets[info->num_brackets].ptr = re + i + 1;
603 info->brackets[info->num_brackets].len = -1;
604 info->num_brackets++;
605 FAIL_IF(info->num_caps > 0 && info->num_brackets - 1 > info->num_caps,
608 int ind = info->brackets[info->num_brackets - 1].len == -1 ?
609 info->num_brackets - 1 : depth;
610 info->brackets[ind].len = (int) (&re[i] - info->brackets[ind].ptr);
612 ind, info->brackets[ind].len, info->brackets[ind].ptr));
620 setup_branch_points(info);
622 return baz(s, s_len, info);
627 struct regex_info info;
629 /* Initialize info structure */
630 info.flags = flags;
631 info.num_brackets = info.num_branches = 0;
632 info.num_caps = num_caps;
633 info.caps = caps;
636 return foo(regexp, (int) strlen(regexp), s, s_len, &info);
3484 * Execute the "svn info" command and parse the result.
3494 * Safe way. Execute "svn info --xml" and parse the result. Search for
3499 String cmd = "svn info --xml";
3512 error("error parsing 'svn info' xml result: %s", outString.c_str());