octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: whitespace and structure access operator


From: Rik
Subject: Re: whitespace and structure access operator
Date: Wed, 25 Nov 2015 08:23:50 -0800

On 11/25/2015 04:43 AM, John W. Eaton wrote:
> On 11/25/2015 03:59 AM, Sebastian Schöps wrote:
>> Rik-4 wrote
>>> Can someone test whether the Matlab interpreter accepts the following
>>> code?
>>>
>>> b .x = 1
>>>
>>> The key is the space between the structure access operator "." and the
>>> initially undefined variable b.  Without the space Octave parses this just
>>> fine.
>>>
>>> --Rik
>>
>>
>> Yes it does (R2015b, Mac):
>>
>>>> b .x = 1
>>
>> b =
>>
>>      x: 1
>
> Thanks.
>
> Rik, do you want me to take a look at fixing this, or do you want to do it?

jwe,

I'm sure this is in the parser which means you are likely to find the
solution faster than me.  I hope it is as simple as having some sort of
rule to eat whitespace in the lexer.  The original bug report that brought
this to my attention was https://savannah.gnu.org/bugs/?42559.

--Rik



reply via email to

[Prev in Thread] Current Thread [Next in Thread]