develooper Front page | perl.perl5.porters | Postings from December 2001

More on MM_* and File::Spec

Dave Rolsky
December 22, 2001 15:30
More on MM_* and File::Spec
Message ID:
There's also some File::Spec functions in ExtUtils::MM_NW5 but there's no
File::Spec::NW5.  MM_NW5 defines ...

- catdir()

- file_name_is_absolute(), but this seems identical to the one in

- path(), also identical to File::Spec::Win32

- canonpath(), substantially similar to File::Spec::Win32 and probably is
an older, buggier version of the Win32 method except that this one has the

      $path .= '.' if $path =~ m#\\$#;

This is in addition to what File::Spec::Win32 does.  I'm not sure what
meaning this has, if any, under Netware.

So it seems like there needs to be a File::Spec::NW5 that subclasses
File::Spec::Win32 and defines catdir()  and _maybe_ has a canonpath like

 sub canonpath {
     my $class = shift;
     my $path = $class->SUPER::canonpath(@_);
     $path .= '.' if $path =~ m#\\$#; # um, \Z instead of $ ??
     return $path
 } Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About