in reply to Confusion over scope of "my" vars
This comes up pretty regularly. For some more discussion, see, for example
(there are more, those are just the first three nodes that Google did find...)