xref: /PHP-8.3/ext/gmp/tests/bug66872.phpt (revision e9f783fc)
1--TEST--
2Bug #66872: Crash when passing string to gmp_testbit
3--EXTENSIONS--
4gmp
5--FILE--
6<?php
7
8try {
9    var_dump(gmp_testbit("abc", 1));
10} catch (\ValueError $e) {
11    echo $e->getMessage() . \PHP_EOL;
12}
13
14?>
15--EXPECT--
16gmp_testbit(): Argument #1 ($num) is not an integer string
17