use strict; sub fhopen {   open(FH, "< shift") or die; } fhopen("somefile.txt"); while() {   print "$_\n"; } close(FH);