|Don't ask to ask, just ask|
Re^2: A refactoring trapby ihb (Deacon)
|on Aug 23, 2005 at 21:47 UTC||Need Help??|
Dispite that many has pointed out that
are identical, your first remark is true. The problem lies elsewhere:
doesn't localize $_ and thus leaves $_ undefined after the loop.
doesn't suffer from this as it doesn't touch $_.
If put in a subroutine this innocent little bug cause a serious headache while trying to find out why $_ all of a sudden is undefined.
See perltoc if you don't know which perldoc to read!