Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!sdd.hp.com!samsung!uunet!zephyr.ens.tek.com!uw-beaver!fluke!dcd From: dcd@tc.fluke.COM (David Dyck) Newsgroups: comp.lang.perl Subject: perldb changes (or bug in manual) Keywords: perldb.pl do require Message-ID: <1990Aug26.055821.22669@tc.fluke.COM> Date: 26 Aug 90 05:58:21 GMT Organization: John Fluke Mfg. Co., Inc., Everett, WA Lines: 50 The perl manual states: If you want to modify the debugger, copy perldb.pl from the perl library to your current directory and modify it as necessary. The source file perldb.pl states: # .... It also inserts a do 'perldb.pl' before the first line. In perl PL18 I could load a custom perldb.pl script in the current directory, and it would get used when invoking 'perl -d'; In PL28 this feature is no longer enabled, and perl (by default) looks in the 'standard library places'. I can use the -I . to cause it to look in the current directory. The sources indicate that PL28 looks for 'perldb.pl' with 'require', and PL18 looked with 'do'. 1) Why doesn't 'require' look in the current directory first? 2) Are the manual and comments in perldb.pl wrong? 3) The reason I wanted to customize the library is I run under SunOS using "on -i hostname" a lot, and the following perldb.pl lines fail: open(IN,"/dev/tty"); # so we don't dingle stdin open(OUT,">/dev/tty"); # so we don't dongle stdout If these line were change to the following I would not need to do this customization. open(IN,"/dev/tty") || open(IN,"<&STDIN"); # so we don't dingle stdin open(OUT,">/dev/tty") || open(OUT,">&STDOUT"); # so we don't dongle stdout Does anyone see anything wrong with making this change? PS. perl patch 28 has not appeared in comp.lang.perl here in the northwest. I was able to get a copy from Larry's patch server. (thanks) David Dyck Domain: dcd@tc.fluke.COM Voice: +1 206 356 5807 UUCP: {uunet,uw-beaver,decwrl,microsof,sun}!fluke!dcd Snail: John Fluke Mfg. Co. / P.O. Box 9090 / Everett WA 98206-9090 / USA