help-octave
[Top][All Lists]
Advanced

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

Re: confusing error message in octave-3.2.4


From: Sergei Steshenko
Subject: Re: confusing error message in octave-3.2.4
Date: Sat, 3 Sep 2011 07:50:51 -0700 (PDT)




----- Original Message -----
> From: Sergei Steshenko <address@hidden>
> To: "address@hidden" <address@hidden>
> Cc: 
> Sent: Saturday, September 3, 2011 4:56 PM
> Subject: confusing error message in octave-3.2.4
> 
> Hello,
> 
> here is a short screen session:
> 
> "
> octave:1> function foo  bar(end) endfunction
> octave:2> foo()
> error: invalid use of end
> error: evaluating argument list element number 1
> error: called from:
> error:   foo at line 1, column 15
> octave:2>    
> 
> ".
> 
> First and foremost, 'bar' is simply undefined, but 'octave'
> says nothing about it.
> 
> The above is a short testcase originating from a real script.
> 
> The 'bar' above in reality is not a function, but a vector,
> I simply forgot to pass it through the function args, i.e.
> it should be
> 
> function foo(bar) bar(end) endfunction
> .
> 
> 
> Is it the way it is supposed to be ? I.e. I think
> 'octave' should have first detected that 'bar' is undefined
> - neither as function nor as data (i.e. vector in this case).
> 
> I.e. I suspect there is a name look up problem.
> 
> 
> Thanks,
>   Sergei.
> 

Sorry, 'octave' version is 3.4.2, not 3.2.4.

Regards,
  Sergei.



reply via email to

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