- Timestamp:
- 09/02/07 15:06:11 (16 months ago)
- Files:
-
- 1 modified
-
ext/File-Spec/lib/File/Spec/Win32.pm (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
ext/File-Spec/lib/File/Spec/Win32.pm
r12776 r17606 48 48 my @path = @_path; 49 49 my @new_path; 50 my $i = 0;51 loop ($i = 0; $i < @path; $i++){52 @path[$i] ~~ s:P5:g"/"\\"; 53 if (@path[$i] ~~ m:P5"\\$"){54 push(@new_path, @path[$i]);50 @new_path = gather { 51 for @path -> $part { 52 53 if $part !~~ m:P5"\\$" { 54 take $part ~ "\\"; 55 55 } 56 56 else { 57 push(@new_path, @path[$i] ~ "\\"); 58 } 59 } 57 take $part; 58 } 59 } 60 }; 61 60 62 return canonpath(join('', @new_path)); 61 63 }
