On 01/22/2011 01:52 PM, Sven Schreiber wrote:
[I]t should be acknowledged that it is a real
limitation of gretl to have only global variables (apart from the
function scope), not to turn that around into a feature.
In my view the gretl script is an arbitrary textual unit, and
it does not make sense to limit the scope of variables based
on the script.
I can see a case for local variables, but these should be local
to non-arbitrary code blocks. For example it would be quite nice
to be able to say, within a loop or an if-block for example,
local matrix foo = whatever
so that the object would be destroyed automatically on exit
from the block. But scripts are not (logically) code blocks.
Allin