/php-src/ext/pcre/tests/ |
H A D | pcre_count.phpt | 5 $regex = '/(([0-9a-z]+)-([0-9]+))-(([0-9]+)-([0-9]+))/'; 9 var_dump(preg_replace($regex, 'xxxx', $string, -1, $count)); 13 $regex = '/([a-z]+)/'; 16 var_dump(preg_replace($regex, 'xxxx', $string, -1, $count)); 20 $regex = '~((V(I|1)(4|A)GR(4|A))|(V(I|1)C(0|O)D(I|1)(N|\/\\\/)))~i'; 23 var_dump(preg_replace($regex, '...', $string, -1, $count)); 26 $regex = '~((V(I|1)(4|A)GR(4|A))|(V(I|1)C(0|O)D(I|1)(N|\/\\\/)))~i'; 29 var_dump(preg_replace($regex, '...', $string, -1));
|
H A D | bug47662.phpt | 6 $regex = '@'; 8 $regex .= '((?P<x'.$bar.'>))'; 11 $regex .= 'fo+bar@'; 13 var_dump(preg_match($regex, 'foobar'));
|
H A D | bug73483.phpt | 5 $regex = "#dummy#"; 7 var_dump(preg_replace_callback($regex, function (array $matches) use($regex) { 9 $ret = preg_replace($regex, "okey", $matches[0]);
|
H A D | gh11374.phpt | 12 $regex = ' 23 $res = preg_match('{^' . $regex . '$}x', '{a}', $matches, PREG_OFFSET_CAPTURE); 25 // regex must be different to prevent regex cache, so just add 2nd "x" modifier 26 $res2 = preg_match('{^' . $regex . '$}xx', '{a}', $matches2, PREG_OFFSET_CAPTURE);
|
H A D | bug70345.phpt | 5 $regex = '/(?=xyz\K)/'; 8 var_dump(preg_split($regex, $subject)); 10 $regex = '/(a(?=xyz\K))/'; 12 preg_match($regex, $subject, $matches);
|
H A D | marks.phpt | 6 $regex = <<<'REGEX' 15 var_dump(preg_match($regex, '_c_', $matches)); 18 var_dump(preg_match_all($regex, '_a__b__c__d_', $matches, PREG_PATTERN_ORDER)); 21 var_dump(preg_match_all($regex, '_a__b__c__d_', $matches, PREG_SET_ORDER)); 24 var_dump(preg_replace_callback($regex, function($matches) {
|
H A D | bug41050.phpt | 7 $regex = '/(insert|drop|create|select|delete|update)([^;\']*('."('[^']*')+".')?)*(;|$)/i'; 11 if (preg_match($regex,$sql, $m)) echo 'matched';
|
H A D | preg_replace_error2.phpt | 11 $regex = '/[a-zA-Z]/'; 16 var_dump(preg_replace($regex, $value, $subject)); 23 var_dump(preg_replace($regex, $value, $subject));
|
H A D | preg_replace_callback.phpt | 10 $regex = '#\[indent]((?:[^[]|\[(?!/?indent])|(?R))+)\[/indent]#'; 16 return preg_replace_callback($regex, 'parseTagsRecursive', $input);
|
H A D | preg_match_all_error3.phpt | 12 $regex = '/[a-z]/'; 14 var_dump(preg_match_all($regex, $subject, 'test'));
|
H A D | bug77827.phpt | 2 Bug #77827 (preg_match does not ignore \r in regex flags)
|
H A D | gh15205_1.phpt | 8 $regex = [new RegexIterator($array, '/Array/')];
|
/php-src/ext/spl/tests/ |
H A D | bug68175.phpt | 6 $regex = new RegexIterator($arr, '/^test/'); 8 $regex->getMode(), 9 $regex->getFlags(), 10 $regex->getPregFlags()
|
H A D | bug68128.phpt | 7 $regex = new RegexIterator($array, '/Array/'); 9 foreach ($regex as $match) {
|
/php-src/ext/mbstring/tests/ |
H A D | retry_limit.phpt | 15 $regex = 'A(B|C+)+D|AC+X'; 17 var_dump(mb_ereg($regex, $str)); 19 var_dump(mb_ereg($regex, $str));
|
H A D | mb_ereg_variation5.phpt | 2 Test mb_ereg() function : usage variations - Test anchors in regex 22 $regex = '^.*?[[:blank:]]?[[:punct:][:digit:]]+\.?$'; 25 var_dump(mb_ereg($regex, $string_ascii)); 27 var_dump(mb_ereg($regex, $string_ascii, $regs_ascii)); 31 var_dump(mb_ereg($regex, $string_mb)); 33 var_dump(mb_ereg($regex, $string_mb, $regs_mb));
|
H A D | bug77370.phpt | 2 Bug #77370 (Buffer overflow on mb regex functions - fetch_token)
|
H A D | bug77371.phpt | 2 Bug #77371 (heap buffer overflow in mb regex functions - compile_string_node)
|
/php-src/ext/fileinfo/tests/ |
H A D | finfo_file_regex.phpt | 2 Test finfo_file() function : regex rules 15 echo "*** Testing finfo_file() : regex rules ***\n"; 24 *** Testing finfo_file() : regex rules ***
|
H A D | bug79283.phpt | 9 0 regex \\0\\0\\0\\0 Test
|
H A D | bug77961.magic | 2 >1 regex \^[0-9:,\ ]*-->[0-9:,\ ]* SubRip File 20 0 regex \^#import Objective-C source text
|
/php-src/ext/pcre/ |
H A D | php_pcre.h | 28 PHPAPI zend_string *php_pcre_replace(zend_string *regex, zend_string *subject_str, const char *subj… 29 PHPAPI pcre2_code* pcre_get_compiled_regex(zend_string *regex, uint32_t *capture_count); 49 PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(zend_string *regex); 50 PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache_ex(zend_string *regex, bool locale_aware);
|
H A D | php_pcre.c | 601 ZSTR_VAL(regex), ZSTR_LEN(regex)); in pcre_get_compiled_regex_cache_ex() 603 key = regex; in pcre_get_compiled_regex_cache_ex() 610 if (key != regex) { in pcre_get_compiled_regex_cache_ex() 616 p = ZSTR_VAL(regex); in pcre_get_compiled_regex_cache_ex() 617 const char* end_p = ZSTR_VAL(regex) + ZSTR_LEN(regex); in pcre_get_compiled_regex_cache_ex() 623 if (key != regex) { in pcre_get_compiled_regex_cache_ex() 635 if (key != regex) { in pcre_get_compiled_regex_cache_ex() 678 if (key != regex) { in pcre_get_compiled_regex_cache_ex() 748 if (key != regex) { in pcre_get_compiled_regex_cache_ex() 878 if (key != regex) { in pcre_get_compiled_regex_cache_ex() [all …]
|
/php-src/ext/fileinfo/ |
H A D | magicdata.patch | 21 0 regex module(\\.|\\[["'])exports.*= JavaScript source 26 0 regex \^(const|var|let).*=.*require\\( JavaScript source 31 0 regex \^export\x20(function|class|default|const|var|let|async)\x20 JavaScript source 36 0 regex \\((async\x20)?function[(\x20] JavaScript source 41 0 regex \^(import|export).*\x20from\x20 JavaScript source 46 0 regex \^(import|export)\x20["']\\./ JavaScript source 51 0 regex \^require\\(["'] JavaScript source 55 0 regex typeof.*[!=]== JavaScript source 100 >14 regex ['"\ \t]*[0-9.]+['"\ \t]*
|
/php-src/ext/spl/ |
H A D | spl_iterators.c | 130 zend_string *regex; member 132 } regex; member 1355 zend_string *regex; in spl_dual_it_construct() local 1358 intern->u.regex.flags = 0; in spl_dual_it_construct() 1371 intern->u.regex.pce = pcre_get_compiled_regex_cache(regex); in spl_dual_it_construct() 1379 intern->u.regex.regex = zend_string_copy(regex); in spl_dual_it_construct() 1866 RETURN_STR_COPY(intern->u.regex.regex); in PHP_METHOD() 1980 ZVAL_STR_COPY(&args[1], intern->u.regex.regex); in PHP_METHOD() 2038 if (object->u.regex.pce) { in spl_dual_it_free_storage() 2041 if (object->u.regex.regex) { in spl_dual_it_free_storage() [all …]
|