3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php declare(strict_types=1); $a = [0, 1, '0', null, '', new \stdClass]; var_dump(array_filter($a));
based on BeAZT
Output for 7.0.28 - 7.3.0rc3
array(2) { [1]=> int(1) [5]=> object(stdClass)#1 (0) { } }
Output for 5.6.38
Warning: Unsupported declare 'strict_types' in /in/CjD8A on line 2 array(2) { [1]=> int(1) [5]=> object(stdClass)#1 (0) { } }