On Tue, 22 Nov 2016, Allin Cottrell wrote:
On Tue, 22 Nov 2016, Sven Schreiber wrote:
> Hi,
> I can copy an array to a bundle, but cannot create it there right away.
> This time I'm not sure whether it's a bug...
>
> <hansl>
> bundle bc = null
> strings s = array(3)
> strings bc.s = s
>
> strings bc.s2 = array(2) # this fails
> </hansl>
>
> (Also fails with matrices array.)
One might say it's a missing feature, but I would say it's a bug. Now fixed
in git.
Another comment on this. At this point we don't support arbitrary
nesting of types on the left-hand side of an assignment, as in
assign a certain value to an element of a matrix, in an array of
matrices, in a bundle, in an array of bundles, ...
This is no doubt something for aim for, though it will take some
thought and careful redesign. However, even now we should support
at least one level of nesting, which is why I'm ready to acknowledge
the failure above as a bug.
Allin