Accessing array elements with a pointer-to-array

Kagamin spam at here.lot
Thu Jan 25 20:36:49 UTC 2024


On Thursday, 25 January 2024 at 20:11:05 UTC, Stephen Tashiro 
wrote:
>     void main()
>     {
>        ulong [3][2] static_array = [ [0,1,2],[3,4,5] ];
>        static_array[2][1] = 6;
>     }

The static array has length 2, so index 2 is out of bounds, must 
be 0 or 1.


More information about the Digitalmars-d-learn mailing list