php-src/Zend/tests/debug_info-error-0.phpt
2020-08-09 22:03:36 +02:00

21 lines
382 B
PHP

--TEST--
Testing __debugInfo() magic method with bad returns ZERO
--FILE--
<?php
class C {
public $val;
public function __debugInfo() {
return $this->val;
}
public function __construct($val) {
$this->val = $val;
}
}
$c = new C(0);
var_dump($c);
?>
--EXPECTF--
Fatal error: __debuginfo() must return an array in %s%eZend%etests%edebug_info-error-0.php on line %d