I haven't considered alignment here. I'm not sure if you have to.
I though all classes were aligned to sizeof(size_t) boundaries? Wouldn't it then just be
align(sizeof(size_t)) byte[__traits(classInstanceSize, SomeClass)] scStorage;
David Zhang via Digitalmars-d-learn Fri, 16 Dec 2016 10:31:28 -0800
I haven't considered alignment here. I'm not sure if you have to.
I though all classes were aligned to sizeof(size_t) boundaries? Wouldn't it then just be
align(sizeof(size_t)) byte[__traits(classInstanceSize, SomeClass)] scStorage;