@ 2018-03-14T09:42:15Z

<?php // usually, the order of a class definition doesn't matter $a = new A(); class A {} // when extending a class and when the parent is defined before the child, it works as well $b = new B(); class baseB {} class B extends baseB{} // but when we try to reverse the order of definition, it fails, // (though for some reason it says it's C, not baseC cannot be found) try { $c = new C(); } catch (Throwable $e){ echo $e->getMessage();} class C extends baseC {} class BaseC{} // So we could think that the order of definition is important // yet we can define D before baseD this way class D extends baseD {} $d = new D(); class baseD{}