xref: /PHP-7.3/ext/bcmath/tests/bug75178.phpt (revision 589f8107)
1--TEST--
2Bug #75178 (bcpowmod() misbehaves for non-integer base or modulus)
3--SKIPIF--
4<?php
5if (!extension_loaded('bcmath')) die('skip bcmath extension is not available');
6?>
7--FILE--
8<?php
9var_dump(bcpowmod('4.1', '4', '3', 3));
10var_dump(bcpowmod('4', '4', '3.1', 3));
11?>
12===DONE===
13--EXPECTF--
14Warning: bcpowmod(): non-zero scale in base in %s on line %d
15string(5) "1.000"
16
17Warning: bcpowmod(): non-zero scale in modulus in %s on line %d
18string(5) "1.000"
19===DONE===
20