several questions

Saaa empty at needmail.com
Sun Feb 17 05:56:40 PST 2008



>> Thanks again,
>>
>> I don't think I ever override a function, should I make them final then, 
>> for optimizing purposes, or is final only for classes?
>
> Are you developing an application or a library?
>
> If it's a library, don't final it unless it's deep in the bowels where 
> nobody will reasonably tread, or unless the library really requires 
> performance.
>
> If it's an application, feel free. You probably won't have much need for 
> inheritance, but then, the optimizations from your final classes might not 
> be that great.

This reads as making a function final will hurt the optimization.
btw. I don't use classes :), only functions.
(application)

>
> But really, it's your decision. 




More information about the Digitalmars-d-learn mailing list