[prev in list] [next in list] [prev in thread] [next in thread]
List: perl5-porters
Subject: Re: dirname("/perl/") == ?
From: Michael G Schwern <schwern () pobox ! com>
Date: 2005-06-30 20:28:40
Message-ID: 20050630202840.GG20875 () windhund ! schwern ! org
[Download RAW message or body]
I have found uses of dirname() that gives me pause about changing the
behavior. People seem to use it as a sort of chop() for directories.
ExtUtils::MM_Unix uses it to infer the Perl source directory from entries
in @INC (which are all directories).
HTML::Mason::Component also appears to use it as a directory chop.
So I'm inclined to (alas) leave it as it is and just document the caveat
better.
PS In my searching I also found this double no-op in Msql-Mysql-modules
amusing
if (-f ($realfile = "$dir/$file")) {
return (File::Basename::dirname($realfile), $dir);
}
--
Michael G Schwern schwern@pobox.com http://www.pobox.com/~schwern
Ahh email, my old friend. Do you know that revenge is a dish that is best
served cold? And it is very cold on the Internet!
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic