Annotation of embedaddon/php/Zend/tests/closure_011.phpt, revision 1.1

1.1     ! misho       1: --TEST--
        !             2: Closure 011: Lexical copies not static in closure
        !             3: --FILE--
        !             4: <?php
        !             5: $i = 1;
        !             6: $lambda = function () use ($i) {
        !             7:     return ++$i;
        !             8: };
        !             9: $lambda();
        !            10: echo $lambda()."\n";
        !            11: //early prototypes gave 3 here because $i was static in $lambda
        !            12: ?>
        !            13: --EXPECT--
        !            14: 2

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>