[Israel.pm] catching $a, $b unnecessary my and maybe other things

Yuval Yaari yuval at windax.com
Sun Jun 6 10:48:19 PDT 2004

I said:
> 1) I thought it's obvious. I've read about it so many times.
> Personally, I hate people who give names like $a and $b (though I did it
> a few times and noticed that problem - but don't tell anyone).
> But it's a well known... bug (?) in strict because of functions such as
> sort.
> 2) Did you try use diagnostics; ?
> Also, use strict; use warnings; and/or use diagnostics; do not replace
> re-reading your code, or debugging it.
> Though they usually solve all of my problems :)

use diagnostics; didn't work.
Keep us updated if you find something...

As for what I said above, I don't really hate people who use $a and $b, I
just prefer normal names for variables (and for crying out loud, your
editor should auto-complete it for you so you write once and M-/ later
[sorry for being emacs-specific]).

I also know a russian programmer who named his variables $NaxuySukaBlat,
But at least strict would work for him in such case :)


More information about the Perl mailing list