[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Structures 6.1.1 Basic Usage and Examples
From: |
Mike Miller |
Subject: |
Re: Structures 6.1.1 Basic Usage and Examples |
Date: |
Tue, 13 May 2014 08:35:30 -0400 |
On Tue, May 13, 2014 at 09:52:11 +0200, Andreas Weber wrote:
> The manual
> http://www.gnu.org/software/octave/doc/interpreter/Basic-Usage-and-Examples.html#Basic-Usage-and-Examples
> shows
>
> x.a = 1;
> x.b = [1, 2; 3, 4];
> x.c = "string";
> x.b.d = 3;
> error: invalid assignment to cs-list outside multiple assignment
>
> which works in Matlab and since it's in the manual I guess this also
> worked in octave somewhen prior 3.6.2.
>
> I'm not sure if this is related to
> https://savannah.gnu.org/bugs/?func=detailitem&item_id=32381
That looks related to me. According to the bug report this worked in
3.2 and was changed for 3.4.
Perhaps fix the manual to use either
x.b = [];
x.b.d = 3;
or
x.b = struct ("d", 3);
instead?
--
mike