nested class inheritance
Gor Gyolchanyan
gor.f.gyolchanyan at gmail.com
Fri Jul 13 12:01:47 PDT 2012
On Fri, Jul 13, 2012 at 10:55 PM, Christophe Travert <
travert at phare.normalesup.org> wrote:
> "Era Scarecrow" , dans le message (digitalmars.D:172272), a écrit :
> > Then perhaps have the inherited class within fruit?
> >
> > class Fruit {
> > class Seed {}
> > class Appleseed : Seed {}
> > }
>
> But then AppleSeed doesn't know about Apple....
>
>
Right. And Fruit.Seed can't know about Apple either, because there are tons
of fruits like Apple, each of which can have tons of different Seeds.
I really didn't get why my original example didn't make sense.
--
Bye,
Gor Gyolchanyan.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20120713/2ad8a370/attachment.html>
More information about the Digitalmars-d
mailing list