3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $db = new stdClass; $db->affected_rows = 1; //affected_rows is type int echo '$db->affected_rows'; var_dump($db->affected_rows); echo 'empty($db->affected_rows)'; var_dump(empty($db->affected_rows)); echo '$db->affected_rows > 0'; var_dump($db->affected_rows > 0);
Output for 4.3.0 - 7.1.0
$db->affected_rowsint(1) empty($db->affected_rows)bool(false) $db->affected_rows > 0bool(true)