- var_dump: documentation ( source)
- set_error_handler: documentation ( source)
- trigger_error: documentation ( source)
<?php
function meh() {
static $a = 10;
$a--;
echo "$a\n";
if ($a > 0) {
var_dump($a);
yield $a;
}
}
set_error_handler('meh');
trigger_error('lol', E_USER_ERROR);