[Nickle]Multidimensional array questions
Keith Packard
keithp@keithp.com
Wed, 21 Mar 2001 10:40:20 -0800
Around 21 o'clock on Mar 20, Barton C Massey wrote:
> Currently, Nickle provides no way to
> initialize multidimensional arrays of
> unspecified dimension:
> [*]{1,2,3}
> works, but
> [*,*]{{1,2},{1,2}}
> is an error.
Just a bug in the grammar. I fixed it.
> Also, currently, Nickle does not allow shenanigans like
> [2,*]{{1,2},{1,2}}
> or even
> [*,2]{{1,2},{1,2}}
> I'm perfectly fine with this "all-or-nothing" approach: an
> array expression must either give all of the dimensions or
> none of them. What do others think?
Can't do it, the parser chokes on allowing either '*' or 'expr' because
'expr' can start with a star (left operators suck). Pick a different
character...
There are still problems with partial array initializers not doing the
right thing, I'll go fix that.
-keith