import zend pcre tests
[hiphop-php.git] / hphp / test / zend / good / ext-pcre / bug44214.php
blob47f21d2e8c119dd5d334a14b4dc1c0043be882df
1 <?php
2 $string = 'aaa bbb ccc ddd eee ccc aaa bbb';
4 $array = array();
6 function myCallBack( $match ) {
7 global $array;
8 $array[] = $match;
9 return 'xxx';
12 var_dump(preg_replace_callback( '`a+`', 'myCallBack', $string));
13 var_dump($array);