summaryrefslogtreecommitdiff
path: root/Zend/tests/inference_infinite_loop.phpt
blob: 1e94ea8040bca968c8b72736bd9463ce54d96d5f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
--TEST--
Type inference should not result in infinite loop
--FILE--
<?php

function test() {
    $b = false;
    do {
        $a = $a + PHP_INT_MAX + 2;
        $a = 0;
    } while ($b);
}
test();

?>
--EXPECTF--
Notice: Undefined variable: a in %s on line %d