xref: /PHP-8.1/Zend/tests/bug72347.phpt (revision b8e380ab)
1--TEST--
2Bug #72347 (VERIFY_RETURN type casts visible in finally)
3--FILE--
4<?php
5function test() : int {
6    $d = 1.5;
7    try {
8        return $d;
9    } finally {
10        var_dump($d);
11    }
12}
13var_dump(test());
14?>
15--EXPECTF--
16Deprecated: Implicit conversion from float 1.5 to int loses precision in %s on line %d
17float(1.5)
18int(1)
19