]> ocean-lang.org Git - ocean/commitdiff
oceani: handle variable-sized arrays better.
authorNeilBrown <neil@brown.name>
Thu, 14 Oct 2021 02:43:02 +0000 (13:43 +1100)
committerNeilBrown <neil@brown.name>
Sat, 30 Oct 2021 22:18:19 +0000 (09:18 +1100)
An array with size set by a constant variable(!) might have a different
size each time the declaration is encountered.  So we need to
re-evaluate the size each time.
We currently re-evaluate the size only if it is zero.

So for numerical-constant sized arrays, evaluate size during parsing.
For other arrays, re-evaulate each time using a new prepare_type method.

Signed-off-by: NeilBrown <neil@brown.name>

No differences found