in reply to Re: Best Practice: How do I pass option parameters to functions?
in thread Best Practice: How do I pass option parameters to functions?

There is a subtle difference, from warnings:
The warnings pragma is a replacement for the command line flag -w , but the pragma is limited to the enclosing block, while the flag is global.
  • Comment on Re^2: Best Practice: How do I pass option parameters to functions? (warnings)

Replies are listed 'Best First'.
Re^3: Best Practice: How do I pass option parameters to functions? (warnings)
by builat (Monk) on Oct 29, 2013 at 17:16 UTC
    Thanks useful info for me.
      "Thanks useful info for me."

      Just to add a little additional info, you'll find '-w' documented in perlrun, with links to further information, and this text:

      "... normally, the lexically scoped use warnings pragma is preferred."

      -- Ken

Re^3: Best Practice: How do I pass option parameters to functions? (warnings)
by An_Idea_Within (Initiate) on Oct 30, 2013 at 09:19 UTC

    Just the header I've copy/pasted into my scripts ever since I started using perl. I'd thought about changing it, but, quite honestly, I'd completely forgotten about it when posting the question. Thanks for the clarification of the differences, though!