xref: /PHP-7.4/ext/bcmath/tests/bug78238.phpt (revision bcb89c75)
1--TEST--
2Bug #78238 (BCMath returns "-0")
3--SKIPIF--
4<?php
5if (!extension_loaded('bcmath')) die("sikp bcmath extension not available");
6?>
7--FILE--
8<?php
9var_dump(bcadd("0", "-0.1"));
10
11$a = bcmul("0.9", "-0.1", 1);
12$b = bcmul("0.90", "-0.1", 1);
13var_dump($a, $b);
14?>
15--EXPECT--
16string(1) "0"
17string(3) "0.0"
18string(3) "0.0"
19