xref: /PHP-7.3/tests/lang/bug17115.phpt (revision eaeecc52)
1--TEST--
2Bug #17115 (lambda functions produce segfault with static vars)
3--FILE--
4<?php
5$func = create_function('','
6	static $foo = 0;
7	return $foo++;
8');
9var_dump($func());
10var_dump($func());
11var_dump($func());
12?>
13--EXPECTF--
14Deprecated: Function create_function() is deprecated in %s on line %d
15int(0)
16int(1)
17int(2)
18