/glibc-2.36/posix/ |
D | tst-rxspencer.c | 217 test (const char *pattern, int cflags, const char *string, int eflags, in test() argument 224 n = regcomp (&re, pattern, cflags); in test() 321 mb_test (const char *pattern, int cflags, const char *string, int eflags, in mb_test() argument 325 char *pattern_mb = mb_frob_pattern (pattern, letters); in mb_test() 351 mb_tests (const char *pattern, int cflags, const char *string, int eflags, in mb_tests() argument 360 if (strstr (pattern, "[:xdigit:]")) in mb_tests() 364 if (strstr (pattern, "[[=b=]]")) in mb_tests() 372 if (!strchr (pattern, 'a') && !strchr (string, 'a') in mb_tests() 373 && !strchr (pattern, 'A') && !strchr (string, 'A')) in mb_tests() 379 if (!strchr (pattern, 'b') && !strchr (string, 'b') in mb_tests() [all …]
|
D | tst-fnmatch5.c | 27 static char pattern[LENGTH + 7]; variable 34 pattern[0] = '['; in do_test() 35 pattern[1] = '['; in do_test() 36 pattern[2] = '.'; in do_test() 37 memset (pattern + 3, 'a', LENGTH); in do_test() 38 pattern[LENGTH + 3] = '.'; in do_test() 39 pattern[LENGTH + 4] = ']'; in do_test() 40 pattern[LENGTH + 5] = ']'; in do_test() 41 TEST_VERIFY (fnmatch (pattern, "a", 0) != 0); in do_test()
|
D | bug-regex19.c | 35 const char *pattern; member 263 err = re_compile_pattern (test->pattern, strlen (test->pattern), in do_one_test() 267 printf ("%sre_compile_pattern \"%s\" failed: %s\n", fail, test->pattern, in do_one_test() 286 fail, test->pattern, test->string, res, test->res); in do_one_test() 307 fail, test->pattern, test->string, res, test->res); in do_one_test() 348 char pattern[strlen (test->pattern) * 4 + 1]; in do_mb_tests() local 353 t.pattern = pattern; in do_mb_tests() 362 if (!strchr (test->pattern, chars[j]) in do_mb_tests() 371 for (j = 0, p = pattern; test->pattern[j]; ++j) in do_mb_tests() 372 if (strchr (repl, test->pattern[j])) in do_mb_tests() [all …]
|
D | tst-pcre.c | 34 char *pattern = NULL, *string = NULL; in main() local 114 pattern = realloc (pattern, p - line); in main() 115 if (pattern == NULL) in main() 124 memcpy (pattern, line + 1, p - line - 1); in main() 125 pattern[p - line - 1] = '\0'; in main() 155 n = regcomp (&re, pattern, in main() 162 linenum, pattern, buf); in main() 190 linenum, pattern, string, rm[0].rm_so, rm[0].rm_eo); in main() 214 linenum, pattern, string, num, in main() 227 linenum, pattern, string, p + 2, num, in main() [all …]
|
D | tst-boost.c | 27 frob_escapes (char *src, int pattern) in frob_escapes() argument 54 if (!pattern) in frob_escapes() 77 char *pattern, *string; in main() local 132 pattern = line + strspn (line, " \t"); in main() 133 if (*pattern == '\0') in main() 135 p = pattern + strcspn (pattern, " \t"); in main() 162 frob_escapes (pattern, 1); in main() 166 n = regcomp (&re, pattern, flags); in main()
|
D | tst-fnmatch3.c | 30 char *pattern = mmap (0, 2 * pagesize, PROT_READ|PROT_WRITE, in do_bz18036() local 32 if (pattern == MAP_FAILED) return 1; in do_bz18036() 34 mprotect (pattern + pagesize, pagesize, PROT_NONE); in do_bz18036() 35 memset (pattern, ' ', pagesize); in do_bz18036() 36 strcpy (pattern, p); in do_bz18036() 38 return fnmatch (pattern, p, FNM_EXTMATCH); in do_bz18036()
|
D | glob.c | 244 static int glob_in_dir (const char *pattern, const char *directory, 302 __glob (const char *pattern, int flags, int (*errfunc) (const char *, int), in __glob() argument 317 if (pattern == NULL || pglob == NULL || (flags & ~__GLOB_FLAGS) != 0) in __glob() 325 if (pattern[0] && pattern[strlen (pattern) - 1] == '/') in __glob() 360 begin = strchr (pattern, '{'); in __glob() 363 begin = pattern; in __glob() 392 size_t pattern_len = strlen (pattern) - 1; in __glob() 404 alt_start = mempcpy (onealt, pattern, begin - pattern); in __glob() 489 filename = strrchr (pattern, '/'); in __glob() 497 filename = strchr (pattern, ':'); in __glob() [all …]
|
D | tst-wordexp-nocmd.c | 56 expect_failure (const char *pattern, int expected_error) in expect_failure() argument 58 printf ("info: testing pattern: %s\n", pattern); in expect_failure() 60 TEST_COMPARE (wordexp (pattern, &w, WRDE_NOCMD), expected_error); in expect_failure() 87 char pattern[256]; in run_tests() local 88 snprintf (pattern, sizeof (pattern), "$[(-%s)/(-1)]", *num); in run_tests() 89 int ret = wordexp (pattern, &w, WRDE_NOCMD); in run_tests()
|
D | tst-fnmatch2.c | 7 char pattern[] = "a*b*c*d*e*f*g*h*i*j*k*l*m*n*o*p*q*r*s*t*u*v*w*x*y*z*"; in do_test() local 10 if (fnmatch (pattern, string, 0) != FNM_NOMATCH) in do_test() 15 pattern[(sizeof pattern) - 3] = '*'; in do_test() 16 if (fnmatch (pattern, string, 0) != 0) in do_test()
|
D | runtests.c | 38 const char * pattern; member 61 if (!last_pattern || strcmp (last_pattern, t->pattern)) in run_a_test() 65 last_pattern = t->pattern; in run_a_test() 66 err = regcomp (&r, t->pattern, REG_EXTENDED); in run_a_test() 85 t->pattern); in run_a_test() 96 t->pattern, t->data, t->expected, err); in run_a_test()
|
D | wordexp.c | 1196 char *pattern; in parse_param() local 1210 pattern = w_newword (&pat_length, &pat_maxlen); in parse_param() 1343 pattern = w_addchar (pattern, &pat_length, &pat_maxlen, '\\'); in parse_param() 1344 if (pattern == NULL) in parse_param() 1366 pattern = w_addchar (pattern, &pat_length, &pat_maxlen, in parse_param() 1368 if (pattern == NULL) in parse_param() 1427 free (pattern); in parse_param() 1486 free (pattern); in parse_param() 1554 for (p = pattern; p && *p; p++) in parse_param() 1642 free (pattern); in parse_param() [all …]
|
D | fnmatch_loop.c | 24 const CHAR *pattern; member 31 static int FCT (const CHAR *pattern, const CHAR *string, 34 static int EXT (INT opt, const CHAR *pattern, const CHAR *string, 39 FCT (const CHAR *pattern, const CHAR *string, const CHAR *string_end, in FCT() argument 42 const CHAR *p = pattern, *n = string; in FCT() 99 ends->pattern = p - 1; in FCT() 166 end.pattern = NULL; in FCT() 208 if (end.pattern == NULL) in FCT() 212 if (end.pattern != NULL) in FCT() 214 p = end.pattern; in FCT() [all …]
|
D | bug-regex11.c | 28 const char *pattern; member 103 n = regcomp (&re, tests[i].pattern, tests[i].flags); in main() 108 printf ("%s: regcomp %zd failed: %s\n", tests[i].pattern, i, buf); in main() 115 printf ("%s: regexec %zd failed\n", tests[i].pattern, i); in main() 128 tests[i].pattern, i, n, rm[n].rm_so, rm[n].rm_eo); in main()
|
D | regex.c | 44 # define regcomp(preg, pattern, cflags) __regcomp (preg, pattern, cflags) argument 55 # define re_compile_pattern(pattern, length, bufp) \ argument 56 __re_compile_pattern (pattern, length, bufp)
|
D | transbug.c | 62 run_test (const char *pattern, struct re_registers *regs) in run_test() argument 84 err = re_compile_pattern (pattern, strlen (pattern), &pat); in run_test() 87 fprintf (stderr, "/%s/: %s\n", pattern, err); in run_test()
|
D | bug-regex20.c | 36 const char *pattern; member 204 err = re_compile_pattern (tests[i].pattern, strlen (tests[i].pattern), in main() 245 err = re_compile_pattern (tests[i].pattern, strlen (tests[i].pattern), in main()
|
D | tst-fnmatch.c | 63 const char *pattern; in do_test() local 89 pattern = next_input (&cp, 0, 0); in do_test() 90 if (pattern == NULL) in do_test() 131 fnmres = fnmatch (pattern, input, flags_val); in do_test() 135 escape (pattern, &escpatternlen, &escpattern), in do_test()
|
/glibc-2.36/libio/ |
D | bug-ungetc4.c | 27 static const char pattern[] = "abcdefghijklmnopqrstuvwxyz"; variable 39 write (fd, pattern, sizeof (pattern) - 1); in do_prepare() 96 if (getc (f) != pattern[TEST_POS]) in do_one_test() 98 printf ("%d: getc did not return %c\n", mode, pattern[TEST_POS]); in do_one_test()
|
D | bug-fseek.c | 20 static const char pattern[] = "12345678901234567890"; in do_prepare() local 28 if (write (fd, pattern, sizeof (pattern)) != sizeof (pattern)) in do_prepare()
|
D | bug-ungetc.c | 11 static const char pattern[] = "12345"; variable 23 write (fd, pattern, sizeof (pattern)); in do_prepare()
|
D | bug-ungetc3.c | 11 static const char pattern[] = "12345"; variable 23 write (fd, pattern, sizeof (pattern)); in do_prepare()
|
D | bug-wsetpos.c | 13 static const char pattern[] = "12345"; variable 25 write (fd, pattern, sizeof (pattern)); in do_prepare()
|
/glibc-2.36/stdlib/ |
D | rpmatch.c | 32 const char *pattern = nl_langinfo (tag); in try() local 33 if (pattern != *lastp) in try() 43 if (__regcomp (re, pattern, REG_EXTENDED) != 0) in try() 45 *lastp = pattern; in try()
|
/glibc-2.36/string/ |
D | test-memmem.c | 133 const char pattern[2] = { 0x78, 0x56 }; in check1() local 139 pattern, sizeof pattern); in check1() 142 pattern, sizeof pattern, exp_result); in check1()
|
/glibc-2.36/scripts/ |
D | test_printers_common.py | 108 def test(command, pattern=None): argument 127 if pattern: 133 index = gdb.expect([u'{0}.+{1}'.format(pattern, gdb_prompt), 139 match = re.match(pattern, gdb.after, re.DOTALL).group() 146 'Response: {2}'.format(command, pattern, gdb.before))
|