From: "Rob Dixon" <[EMAIL PROTECTED]> > There was an example in there that demonstrated > using 'our' to implement a C-like 'static' variable.
Well ... if you mean something like int Inc() { static int cnt; return cnt++; } then our() is not the right way to do that in Perl. the our() only allows you to use the short name instead of $the::complete::one. This is the way: { my $cnt=0; sub Inc { return $cnt++; } } This way the variable is accessible only from the function and no other code can tinker with it. Jenda ===== [EMAIL PROTECTED] === http://Jenda.Krynicky.cz ===== When it comes to wine, women and song, wizards are allowed to get drunk and croon as much as they like. -- Terry Pratchett in Sourcery -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]