Can we just have struct inheritence already?

Olivier FAURE couteaubleu at gmail.com
Tue Jun 18 18:30:58 UTC 2019


On Tuesday, 18 June 2019 at 09:23:45 UTC, Walter Bright wrote:
> As for struct inheritance, it seems what Manu really wants 
> isn't struct inheritance at all, it is zero sized structs 
> having zero size when they are used as fields.

Quick question, have you considered the following syntax:

     align(0) struct MyEmptyStruct {};

or some other means of saying "I don't intend to take this 
struct's address, I don't mind if it takes zero bytes of space"?


More information about the Digitalmars-d mailing list