[OT] Re: Why is $_ being change.

2003-07-11 Thread Elias Assmann
On Thu, Jul 10, 2003 at 08:39:05PM -0700, [EMAIL PROTECTED] wrote: > > Geez, is that your real name? Yes, it is. However, where I live, few people find it remarkable. If I ever felt bad about it, maybe laughing a bit about Johnny Depp's name would cheer me up ("Depp" means "idiot" in German

RE: Why is $_ being change.

2003-07-10 Thread Paul Kraus
From: "Paul Kraus" <[EMAIL PROTECTED]> > That did correct the problem. I don't understand what local $_; did. > So a while loop will change $_ if it is inside a foreach loop since > both use $_? Please do not top-post! local stores the actual value of a global variable, undefines it and restor

RE: Why is $_ being change.

2003-07-10 Thread Jenda Krynicky
From: "Paul Kraus" <[EMAIL PROTECTED]> > That did correct the problem. I don't understand what local $_; did. > So a while loop will change $_ if it is inside a foreach loop since > both use $_? Please do not top-post! local stores the actual value of a global variable, undefines it and restores

Re: Why is $_ being change.

2003-07-10 Thread Elias Assmann
On Thu, Jul 10, 2003 at 12:28:17PM -0400, Paul Kraus wrote: > That did correct the problem. I don't understand what local $_; did. > So a while loop will change $_ if it is inside a foreach loop since both > use $_? Read M.J. Dominus' "Coping with Scoping", available at http://perl.plover.com/FAQ

RE: Why is $_ being change.

2003-07-10 Thread Paul Kraus
bject: Re: Why is $_ being change. From: "Paul Kraus" <[EMAIL PROTECTED]> > I have two subroutines that are have unexpected results. The first is > passed an array ref to a list of file names. It then calls a > subroutine and passes a file name to that subroutine.

Re: Why is $_ being change.

2003-07-10 Thread Jenda Krynicky
From: "Paul Kraus" <[EMAIL PROTECTED]> > I have two subroutines that are have unexpected results. The first is > passed an array ref to a list of file names. It then calls a > subroutine and passes a file name to that subroutine. When that > routine finishes everything in the @files that was passed