Automatic method overriding in sub-classes

Jacob Carlborg via Digitalmars-d digitalmars-d at puremagic.com
Tue Oct 27 13:51:51 PDT 2015


On 2015-10-27 09:05, Tofu Ninja wrote:

> The method is instantiated when the subclass is defined so T would
> obviously be right on hand. Sub-classing a class with an auto override
> method would implicitly instantiate and override the method. Calling
> a.bar() would have no problems because bar would be virtual.

Hmm, interesting.

-- 
/Jacob Carlborg


More information about the Digitalmars-d mailing list