$ perle 'sub f { open my $fh, "<", "not_a_file" }; sub g { f }; g;' Can't open 'not_a_file' for reading: 'No such file or directory' at -e line 1 main::open(GLOB(0x7fb28e80f750), "<", "not_a_file") called at -e line 1 main::f() called at -e line 1 main::g() called at -e line 1