News for hackers. Stuff that matters.
Re:Perl: When DWIM Doesn't by ccashell on Wednesday February 01, 2012 @12:15PM (#3538882)
I think it's a pretty weak reason to give up on a language because you were using a global variable and expecting it to automatically be treated as a local variable within your function.

As others have mentioned, you are using a global variable ($_) inside a function. This is generally considered a bad practice.

The standard perl idiom of getting your function arguments via shift would make this a non-issue.

There are no comments on this comment yet.