Proposal: .isizeof property for compile-time instance size

Frank Benoit benoit__ at __tionex.de
Mon Apr 10 11:39:48 PDT 2006


> I'd rather see my proposal implemented, and then classes be in terms of
> true references and then ad a "psizeof" to get the size of the physical
> pointer or stack variable.  Of course, I would be bias toward my
> proposal. :)

If you have a template for type T and want to know the size for storing
it T.sizeof should return 4 for a reference type.
So it seems to me, a new name like ".isizeof" is better.



More information about the Digitalmars-d mailing list