S
Slain
I have this question about what type of object is a memory block when
you have inheritance going on
Class A
{
blah blah blah
}.
Class B : public Class A
{
blah blah blah
}
Class C : public Class B
{
..
..
static A *f1();
};
A* C::f1()
{
return new C();
}
The memory allotted by the line "return new C()", would be what kind
of object?
Thanks in anticipation
you have inheritance going on
Class A
{
blah blah blah
}.
Class B : public Class A
{
blah blah blah
}
Class C : public Class B
{
..
..
static A *f1();
};
A* C::f1()
{
return new C();
}
The memory allotted by the line "return new C()", would be what kind
of object?
Thanks in anticipation