global problems
Mark Wieder
mwieder at ahsoftware.net
Mon Aug 1 21:35:30 EDT 2005
Ken-
Monday, August 1, 2005, 5:47:01 PM, you wrote:
>> Constants
>> certainly don't.
> Well, why would they? They're opposite things to variables.
Right... well, the point I was trying to make is that there's
*nothing* else that has this persistence. Maybe I chose a bad example.
> Globals are for what they say they are. A global declared during
> runtime _should_ be available in any open stack. Why would you want to
> get rid of it, i.e., that's what they're for. Unless you want to do a
> one-time setup to initialize multiple stacks, then destroy it. Of
> course you could do the same thing with custom props, but it would be
> more awkward.
Maybe I'm missing something about globals here, but since you have to
reference a global explicitly in a script in order to use it, I don't
see why the global should persist if the stack that declared it is
removed from memory.
In other words, if I'm foolish enough to declare a "global x" in a
piece of test code, why should that continue to haunt me when I dump
my test stack and then open a completely different stack that happens
to have a "local x" declaration in it? Am I missing something basic?
--
-Mark Wieder
mwieder at ahsoftware.net
More information about the use-livecode
mailing list