[dmd-beta] 2.067.0-b2

Martin Nowak via dmd-beta dmd-beta at puremagic.com
Wed Feb 18 15:51:44 PST 2015


On 02/18/2015 07:20 PM, Jacob Carlborg wrote:
>
> Yeah. Classes and methods need to be designed to be overridden. There’s a book, Effective Java (similar to Effective C++), which recommends all methods should be final unless explicitly designed to be virtual.

If you care about ABI compatibility on top of API compat, avoid classes 
and use interfaces instead. Because adding a single field in the base 
class changes it's size and breaks the ABI.
And obviously classes shouldn't be abused for code reuse.


More information about the dmd-beta mailing list