Annotation of embedaddon/php/ext/pcre/tests/bug40909.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: Bug #40909 (pcre 7.0 regression)
3: --FILE--
4: <?php
5:
6: $pattern =
7: "/\s([\w_\.\/]+)(?:=([\'\"]?(?:[\w\d\s\?=\(\)\.,'_#\/\\:;&-]|(?:\\\\\"|\\\')?)+[\'\"]?))?/";
8: $context = "<simpletag an_attribute=\"simpleValueInside\">";
9:
10: $match = array();
11:
12: if ($result =preg_match_all($pattern, $context, $match))
13: {
14:
15: var_dump($result);
16: var_dump($match);
17: }
18:
19: ?>
20: --EXPECT--
21: int(1)
22: array(3) {
23: [0]=>
24: array(1) {
25: [0]=>
26: string(33) " an_attribute="simpleValueInside""
27: }
28: [1]=>
29: array(1) {
30: [0]=>
31: string(12) "an_attribute"
32: }
33: [2]=>
34: array(1) {
35: [0]=>
36: string(19) ""simpleValueInside""
37: }
38: }
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>