help-octave
[Top][All Lists]
Advanced

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

unexpected syntax error when defining a global variable?


From: Nicholas Jankowski
Subject: unexpected syntax error when defining a global variable?
Date: Tue, 21 Apr 2015 12:43:52 -0400

simple example:

-------------------
>> segments = 5;
>> p_i(1:segments+1)= 0
p_i =

   0   0   0   0   0   0

BUT

>> segments = 5;
>> global p_i(1:segments+1)= 0
parse error:
  syntax error
>>> global p_i(1:segments+1)= 0
                             ^
-----------------------------------
if the characters spacing is messed up, it's pointing to the (

Is that supposed to happen? I didn't think a global designation was supposed to change anything with syntax. bug?

Nick J.

reply via email to

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