D vs. placement new (for classes) aka why D needs .sizeof and
Dan
murpsoft at hotmail.com
Mon Apr 16 08:44:31 PDT 2007
Okay, so my summary so far:
- having the ability to define a getter/setter using the same syntax as a property means defining simple getter/setter methods is pointless.
- having simple getter/setters is loss-less as it's inlined anyways; it's just messy source.
- at least many of us agree that interfaces and refactoring trump inheritance.
- it would be cool if structs could be made to conform to interfaces.
- it would be cool if getting the sizeof and alignof a class was easier.
- encapsulation is useful only because it prevents people from lazily circumventing interfaces. Is it possible for a module to make everything private except the interfaces? (enforcement by denying access to the symbols at compile time?)
- there is no longer a benefit to having the code and data local to one another on the modern x86 platform because code and data have separate dedicated cache regions.
More information about the Digitalmars-d
mailing list