3v4l.org

run code in 200+ php & hhvm versions
<?php bcscale(2); print bcadd('-0.0', '-0.0') . '<br>'; // prints: -0.00, should be: 0.00 print bccomp('-0.0', '0') . '<br>'; // prints: -1, should be: 0
based on 9EKHc
Output for 7.1.20 - 7.2.6
0.00<br>0<br>
Output for 5.6.0 - 5.6.30, hhvm-3.18.4 - 3.21.0, 7.0.0 - 7.1.9
-0.00<br>-1<br>