File:
[ELWIX - Embedded LightWeight unIX -] /
embedaddon /
php /
ext /
pcre /
tests /
preg_replace_callback3.phpt
Revision
1.1.1.1 (vendor branch):
download - view:
text,
annotated -
select for diffs -
revision graph
Tue Feb 21 23:47:59 2012 UTC (12 years, 6 months ago) by
misho
Branches:
php,
MAIN
CVS tags:
v5_4_3elwix,
v5_4_29p0,
v5_4_29,
v5_4_20p0,
v5_4_20,
v5_4_17p0,
v5_4_17,
v5_3_10,
HEAD
php
--TEST--
preg_replace_callback() 3
--FILE--
<?php
var_dump(preg_replace_callback());
var_dump(preg_replace_callback(1));
var_dump(preg_replace_callback(1,2));
var_dump(preg_replace_callback(1,2,3));
var_dump(preg_replace_callback(1,2,3,4));
$a = 5;
var_dump(preg_replace_callback(1,2,3,4,$a));
$a = "";
var_dump(preg_replace_callback("","","","",$a));
$a = array();
var_dump(preg_replace_callback($a,$a,$a,$a,$a));
echo "Done\n";
?>
--EXPECTF--
Warning: preg_replace_callback() expects at least 3 parameters, 0 given in %s on line %d
NULL
Warning: preg_replace_callback() expects at least 3 parameters, 1 given in %s on line %d
NULL
Warning: preg_replace_callback() expects at least 3 parameters, 2 given in %s on line %d
NULL
Warning: preg_replace_callback(): Requires argument 2, '2', to be a valid callback in %s on line %d
int(3)
Warning: preg_replace_callback(): Requires argument 2, '2', to be a valid callback in %s on line %d
int(3)
Warning: preg_replace_callback(): Requires argument 2, '2', to be a valid callback in %s on line %d
int(3)
Warning: preg_replace_callback() expects parameter 4 to be long, string given in %s on line %d
NULL
Warning: preg_replace_callback() expects parameter 4 to be long, array given in %s on line %d
NULL
Done
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>