diff options
Diffstat (limited to 'ext/bcmath/tests/bug46781.phpt')
-rw-r--r-- | ext/bcmath/tests/bug46781.phpt | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/ext/bcmath/tests/bug46781.phpt b/ext/bcmath/tests/bug46781.phpt new file mode 100644 index 0000000000..caffe83860 --- /dev/null +++ b/ext/bcmath/tests/bug46781.phpt @@ -0,0 +1,16 @@ +--TEST-- +Bug #46781 (BC math handles minus zero incorrectly) +--SKIPIF-- +<?php +if (!extension_loaded('bcmath')) die('skip bcmath extension is not available'); +?> +--FILE-- +<?php +var_dump(bcadd('-0.0', '-0.0', 1)); +var_dump(bccomp('-0.0', '0', 1)); +?> +===DONE=== +--EXPECT-- +string(3) "0.0" +int(0) +===DONE=== |