1--TEST-- 2Bug #70423 Warning Internal error: wrong size calculation 3--INI-- 4open_basedir=. 5opcache.enabled=1 6opcache.enable_cli=1 7opcache.log_verbosity_level=2 8--SKIPIF-- 9<?php require_once('skipif.inc'); ?> 10--FILE-- 11<?php 12 13/* forked from Zend\tests\bug53958.phpt */ 14 15 16// TEST 1 17$a = 1; 18$fn1 = function() use ($a) {echo "$a\n"; $a++;}; 19$fn2 = function() use ($a) {echo "$a\n"; $a++;}; 20$a = 5; 21$fn1(); // 1 22$fn2(); // 1 23$fn1(); // 1 24$fn2(); // 1 25 26// TEST 2 27$b = 1; 28$fn1 = function() use (&$b) {echo "$b\n"; $b++;}; 29$fn2 = function() use (&$b) {echo "$b\n"; $b++;}; 30$b = 5; 31$fn1(); // 5 32$fn2(); // 6 33$fn1(); // 7 34$fn2(); // 8 35 36// TEST 3 37$c = 1; 38$fn1 = function() use (&$c) {echo "$c\n"; $c++;}; 39$fn2 = function() use ($c) {echo "$c\n"; $c++;}; 40$c = 5; 41$fn1(); // 5 42$fn2(); // 1 43$fn1(); // 6 44$fn2(); // 1 45 46// TEST 4 47$d = 1; 48$fn1 = function() use ($d) {echo "$d\n"; $d++;}; 49$fn2 = function() use (&$d) {echo "$d\n"; $d++;}; 50$d = 5; 51$fn1(); // 1 52$fn2(); // 5 53$fn1(); // 1 54$fn2(); // 6 55?> 56--EXPECT-- 571 581 591 601 615 626 637 648 655 661 676 681 691 705 711 726 73