in reply to Re^4: use has it's own scope?in thread use has it's own scope?
Simpler examples of declaration inside of an expression:
open(my $fh, ...) [download]
( my $x = $y ) =~ s/.../.../; [download]