struct inheritance need?
bearophile
bearophileHUGS at lycos.com
Tue Dec 16 06:14:37 PST 2008
Weed:
> Planned in the future to implement inheritance of structs or the static
> creation of classes?
Inheritance of structs: I think it's not planned. Structs in D are meant to be used for different things than classes.
Yet, as time passes structs are gaining more power: you can't believe that very recently they have gained constructors/destructors too in D2. Probably in a system language conceptual purity isn't much appreciated :-)
Static creation of classes (I think you mean creation of objects): it sounds like an interesting thing, I know of a system language that allows the creation of objects only at compile-time, and at compile-time it also performs several space optimizations among such objects (and such space optimizations often improve running speed a little).
Bye,
bearophile
More information about the Digitalmars-d-learn
mailing list