<?php class A { static public function fromStuff() { return new self; } } class B extends A{}; $x = B::fromStuff(); var_dump($x);
You have javascript disabled. You will not be able to edit any code.