What is the order of resolution for super() calls?
anonymous via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Wed Aug 5 12:44:03 PDT 2015
On Wednesday, 5 August 2015 at 12:32:48 UTC, cym13 wrote:
> For reference, as the diagram was unreadable, I'll describe it
> here:
>
> class Adam ;
> class Eve ;
> class Abel:Adam,Eve ;
> class Cain:Adam,Eve ;
> class David:Abel,Cain ;
This is illegal D. You must use interfaces to simulate multiple
inheritance:
"D classes support the single inheritance paradigm, extended by
adding support for interfaces."
see more here: http://dlang.org/class.html
More information about the Digitalmars-d-learn
mailing list