Can we just have struct inheritence already?
Mike Parker
aldacron at gmail.com
Fri Jun 14 07:21:33 UTC 2019
On Friday, 14 June 2019 at 05:59:25 UTC, Manu wrote:
>> So you want
>>
>> class Foo : BaseClass {}
>>
>> and
>>
>> struct Bar : BaseStruct {}
>>
>> to produce two different results?
>
> Well, one's a class and the other's a struct, and that means
> what it means.
It means inconsistency, IMO, and a new violation of the principle
of least astonishment. I have nothing against the behavior you
want, but if it's going to behave differently from polymorphic
inheritance, then it should look different.
More information about the Digitalmars-d
mailing list