summaryrefslogtreecommitdiff
path: root/Zend/tests/closure_052.phpt
blob: 5550cc92dc7074a4f9f7f30b6a275e186f565e4a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
--TEST--
Closure 052: static::class in non-static closure in static method.
--FILE--
<?php

class A {
    static function foo() {
        $f = function() {
            return static::class;
        };
        return $f();
    }
}

class B extends A {}

var_dump(B::foo());
--EXPECT--
string(1) "B"