1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00
Files
archived-php-src/Zend/tests/bitwise_not_precision_exception.phpt

16 lines
320 B
PHP

--TEST--
Promoting float precision warning to exception in bitwise_not
--FILE--
<?php
set_error_handler(function($_, $msg) {
throw new Exception($msg);
});
try {
var_dump(~INF);
} catch (Exception $e) {
echo $e->getMessage(), "\n";
}
?>
--EXPECT--
The float INF is not representable as an int, cast occurred