summaryrefslogtreecommitdiff
path: root/lib/File/Spec/Unix.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/File/Spec/Unix.pm')
-rw-r--r--lib/File/Spec/Unix.pm6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/File/Spec/Unix.pm b/lib/File/Spec/Unix.pm
index 18f7652085..6cec7577aa 100644
--- a/lib/File/Spec/Unix.pm
+++ b/lib/File/Spec/Unix.pm
@@ -356,14 +356,14 @@ sub abs2rel {
my($self,$path,$base) = @_;
$base = $self->_cwd() unless defined $base and length $base;
- for ($path, $base) { $_ = $self->canonpath($_) }
+ ($path, $base) = map $self->canonpath($_), $path, $base;
if (grep $self->file_name_is_absolute($_), $path, $base) {
- for ($path, $base) { $_ = $self->rel2abs($_) }
+ ($path, $base) = map $self->rel2abs($_), $path, $base;
}
else {
# save a couple of cwd()s if both paths are relative
- for ($path, $base) { $_ = $self->catdir('/', $_) }
+ ($path, $base) = map $self->catdir('/', $_), $path, $base;
}
my ($path_volume) = $self->splitpath($path, 1);