1 package File::Spec::Epoc;
5 use vars qw($VERSION @ISA);
9 require File::Spec::Unix;
10 @ISA = qw(File::Spec::Unix);
14 File::Spec::Epoc - methods for Epoc file specs
18 require File::Spec::Epoc; # Done internally by File::Spec if needed
22 See File::Spec::Unix for a documentation of the methods provided
23 there. This package overrides the implementation of these methods, not
26 This package is still work in progress ;-)
44 No physical check on the filesystem, but a logical cleanup of a
45 path. On UNIX eliminated successive slashes and successive "/.".
52 my ($self,$path) = @_;
54 $path =~ s|/+|/|g; # xx////xx -> xx/xx
55 $path =~ s|(/\.)+/|/|g; # xx/././xx -> xx/xx
56 $path =~ s|^(\./)+||s unless $path eq "./"; # ./xx -> xx
57 $path =~ s|^/(\.\./)+|/|s; # /../../xx -> xx
58 $path =~ s|/\Z(?!\n)|| unless $path eq "/"; # xx/ -> xx