global statement removal: hphp/test [7/x]
[hiphop-php.git] / hphp / test / quick / generator_method.php
blob9c82fb87d7dc60a7f9a89c903d0d87f7c24e0ed9
1 <?hh
3 class A {
4 public function Gen() {
5 var_dump($this);
6 yield 1; yield 2; yield 3;
9 public static function SGen() {
10 var_dump(static::class);
11 yield 4; yield 5; yield 6;
16 $a = new A();
17 foreach ($a->Gen() as $num) { var_dump($num); }
18 foreach (A::SGen() as $num) { var_dump($num); }