1--TEST--
2A static method can be a generator
3--FILE--
4<?php
5
6class Test {
7    public static function gen() {
8        var_dump(get_class());
9        var_dump(get_called_class());
10        yield 1;
11        yield 2;
12        yield 3;
13    }
14}
15
16class ExtendedTest extends Test {
17}
18
19foreach (ExtendedTest::gen() as $i) {
20    var_dump($i);
21}
22
23?>
24--EXPECTF--
25Deprecated: Calling get_class() without arguments is deprecated in %s on line %d
26string(4) "Test"
27string(12) "ExtendedTest"
28int(1)
29int(2)
30int(3)
31