Turns out the CLR provides a template array definition that allows n-dimensional (not jagged) arrays:
array<int^, 2>
creates a 2-d array of int.
Code:
array<int^, 2> n = gcnew array<int^, 2> (3, 4);
I have a class that has such an array in it, and a 2-arg constructor. The ctor allocates the array as follows:
Code:
Hexes = gcnew array<Hex^, 2>( _x, _y );
One of the weird things (to me) about Java and .Net languages is that creating an array doesn't create the underlying objects. Map^m = gcnew Map(2, 3) creates a 6-element 2-d array. I have an output statement in the Hex ctor that does not get called.