php-src/Zend/tests/bug70804.phpt
Andrea Faulds 42c8f5e91d Fix bug #70804
This follows on from a4648ded43 and
4e01269082.
Both -(+0.0) and +(-0.0) behaved incorrectly for the same reason.
2015-12-19 02:25:44 +00:00

18 lines
213 B
PHP

--TEST--
Bug #70804 (Unary add on negative zero produces positive zero)
--FILE--
<?php
var_dump(+(-0.0));
var_dump(+(float)"-0");
$foo = +(-sin(0));
var_dump($foo);
?>
--EXPECT--
float(-0)
float(-0)
float(-0)