Jonathan Scott Duff wrote:
Maybe it's just my BASIC upbringing, but "shape" doesn't seem like the
right word. Words like "dimension" and "cardinal" fit better in my head, but I'd want them shorter and "dim" and "card" don't quite work either ;-)
But "shape" makes me want to do something like this:
my num @a is shape('triangle'); my num @b is shape('octagon'); my num @c is shape('square');
That might make sense for triangles, but not the others (unless I'm just suffering a failure of imagination)
I think 'shape' fits better than 'cardinal' or 'dimension'; these things have a 'dimension' that is distinct from their shape (e.g., C<my int @a is shape(3;4;5);> has three dimensions). 'shape' implies the topology of the array; though I can see how it would be easy to assume 'shape' means 'polygon'.
Think of it more like "the shape of ships, the shape of ships, the shape of water when it drips" (_The Shape of Me and Other Things_ , Dr. Suess). A teapot and a mobius strip both have very different shapes with very different features, as do a sparse array and a quaternion.
Forgive me if I come across pedantic; I'm just trying to provide some examples of thinking in terms of 'shape' as Perl 6 defines it.
Gregory Keeney
Anyway ...my two cents. If "shape" is carved in stone, I'll live with it :)
See, a stone has another shape! <grin>