summaryrefslogtreecommitdiff
path: root/Zend/tests/closure_045.phpt
blob: c6276be47b60dbf26318361a8c84e130a33fe96b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
--TEST--
Closure 045: Closures created in static methods are not implicitly static
--FILE--
<?php

class A {
    static function foo() {
        return function () {};
    }
}

$a = A::foo();
$a->bindTo(new A);

echo "Done.\n";

--EXPECTF--
Done.