xref: /PHP-8.2/ext/bcmath/tests/bug78878.phpt (revision 56f90492)
1--TEST--
2Bug #78878 (Buffer underflow in bc_shift_addsub)
3--EXTENSIONS--
4bcmath
5--FILE--
6<?php
7try {
8    print bcmul("\xB26483605105519922841849335928742092", bcpowmod(2, 65535, -4e-4));
9} catch (\ValueError $e) {
10    echo $e->getMessage() . \PHP_EOL;
11}
12?>
13--EXPECT--
14bcpowmod(): Argument #3 ($modulus) cannot have a fractional part
15