Static array initialisation

DLearner bmqazwsx123 at gmail.com
Wed Mar 31 17:27:44 UTC 2021


Hi

I did:
    immutable uint  MemSize=100;  // Memory size in bytes.

// Memory Pool
    ubyte[MemSize]  MemPool = 8;

And had a look in memory.
I think the compiler set up 101 '8's, not 100 in memory.

Which I did not expect.

Best regards



More information about the Digitalmars-d-learn mailing list