http://www.perlmonks.org?node_id=475350


in reply to Annoying warnings...

I think that the solution you imply of turning them off locally is the preferred one. Leave warnings on during development, and when you are sure you want to allow $foo to be undefined,

{ no warnings 'uninitialized'; # edit - corrected tag print "Say something about $foo.\n"; }
That is a pain, as you say, but it makes you ask whether you really need the behavior you're warned of.

Most warnings (not all!) represent some kind of useless behavior in a program. Cleaning them up nearly always improves the code.

After Compline,
Zaxo