To make it simple, this code will give you a seg fault:
class A
{
function __construct()
{
new B;
}
}
class B extends A
{
}
new A;
Don't create new objects from classes that inherit from the class you are creating the object. Yes sounds confusing, and probably it makes no sense but i think the code above is enough to explain it.
No comments:
Post a Comment