blob: 7b58077e95afc9eecd336feba3ba763b80e77733 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
--TEST--
Test array_diff when non-array is passed
--FILE--
<?php
//-=-=-=-=-
$a = array();
$b = 3;
$c = array(5);
try {
array_diff($a, $b, $c);
} catch (TypeError $e) {
echo $e->getMessage(), "\n";
}
//-=-=-=-=-=-
echo "OK!";
?>
--EXPECT--
array_diff(): Argument #2 must be of type array, int given
OK!
|