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


in reply to Re^2: grep2 (like 'grep', but also return non-matches)
in thread grep2 (like 'grep', but also return non-matches)

perlsyn sez about foreach:

...the variable is implicitly local to the loop and regains its former value upon exiting the loop.

So I think this is quite safe.

=cut
--Brent Dax
There is no sig.