Final by default?

Manu turkeyman at gmail.com
Thu Mar 13 20:56:41 PDT 2014


On 14 March 2014 07:42, Walter Bright <newshound2 at digitalmars.com> wrote:

> On 3/13/2014 1:09 PM, Andrei Alexandrescu wrote:
>
>> Also let's not forget that a bunch of people will have not had contact
>> with the
>> group and will not have read the respective thread. For them -- happy
>> campers
>> who get work done in D day in and day out, feeling no speed impact
>> whatsoever
>> from a virtual vs. final decision -- we are simply exercising the brunt
>> of a
>> deprecation cycle with undeniable costs and questionable (in Walter's and
>> my
>> opinion) benefits.
>>
>
> Also,
>
>     class C { final: ... }
>
> achieves final-by-default and it breaks nothing.
>

It does nothing to prevent the library case, or the don't-early-optimise
case of implying breaking changes in the future.

Please leave the virtual keyword as commit by Daniel Murphy in there.
'final:' is no use without a way to undo it for the few instances that
should be virtual. It also really helps C++ portability.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/digitalmars-d/attachments/20140314/1a8b2f85/attachment.html>


More information about the Digitalmars-d mailing list