[Pdx-pm] require './file' vs. require 'file'
Eric Wilhelm
scratchcomputing at gmail.com
Sun Jun 18 02:31:15 PDT 2006
# from Austin Schutz
# on Friday 16 June 2006 01:02 pm:
>use lib '/usr/local/apache/cgi-bin/my';
fair enough
>and
>
>require 'my_lib.pl';
no. use my_lib;
strace -o /tmp/stracefile perl -e "require './my_lib.pl'"
grep my_lib.pl /tmp/stracefile | grep '^open' | sed 's/ .*//'
strace -o /tmp/stracefile perl -e "require 'my_lib.pl'"
grep my_lib.pl /tmp/stracefile | grep '^open' | sed 's/ .*//'
On my box, the output shows searches through hither and yon in the
second case.
--Eric
--
I arise in the morning torn between a desire to improve the world and a
desire to enjoy the world. This makes it hard to plan the day.
--E.B. White
---------------------------------------------------
http://scratchcomputing.com
---------------------------------------------------
More information about the Pdx-pm-list
mailing list