in reply to Re: <STDIN> not initializing $_
in thread <STDIN> not initializing $_

> Yeah, and since $_ can get silently overwritten [...]

Just about as silently as every other variable in Perl. No matter what your own preferences may be, '$_' is an important and integral part of Perl - and there's no reason to give misleading advice to someone who is trying to learn about it.

> [...] I really hate to use it.

Say 'goodbye' to grep and map, then. In fact, bid 'good night' to half the functionality of most Perl functions.


-- 
Human history becomes more and more a race between education and catastrophe. -- HG Wells

Replies are listed 'Best First'.
Re^3: <STDIN> not initializing $_
by wade (Pilgrim) on May 01, 2008 at 05:10 UTC
    I'm just saying that I like to assign values to variables explicitly when possible. I think it's clearer and a little less error-prone but that's just me.
    --
    Wade