P
Peng Yu
Hi,
According to http://perldoc.perl.org/File/Spec.html, no_upwards should
remove '.' or '..'. But the following example does not do so. Can
somebody let me know how to use no_upwards correctly?
Thanks,
Peng
#!/usr/bin/perl
use warnings;
use strict;
use File::Spec;
my @path = ("../../../something/backup/home/../home/Desktop/");
File::Spec->no_upwards(@path);
print "\@path = @path\n";
According to http://perldoc.perl.org/File/Spec.html, no_upwards should
remove '.' or '..'. But the following example does not do so. Can
somebody let me know how to use no_upwards correctly?
Thanks,
Peng
#!/usr/bin/perl
use warnings;
use strict;
use File::Spec;
my @path = ("../../../something/backup/home/../home/Desktop/");
File::Spec->no_upwards(@path);
print "\@path = @path\n";