help-octave
[Top][All Lists]
Advanced

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

problem of using global declaration:-)


From: John W. Eaton
Subject: problem of using global declaration:-)
Date: Mon, 26 Oct 1998 20:48:25 -0600 (CST)

On 27-Oct-1998, Yip Fai <address@hidden> wrote:

| I have a question about using global declaration. When the global
| variable is operated by isempty inside a function, octave tell me that
| the variable is undefined. However, if the variable is defined as
| following.
| 
| global a = [];
| 
| inside the function, the operation goes on without error. But this
| declaration causes drawback of using a function whenever I want. Is
| there any better way to declare a global variable?

Maybe the behavior that you want would be given by setting the
following built-in variables:

  initialize_global_variables = 1;
  default_global_variable_value = [];

These variables were introduced in version 2.0.11.

jwe



reply via email to

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