class IO::Spec::QNX is IO::Spec::Unix { }
An object of this type is available via the variable $*SPEC
if the Raku interpreter is running on a QNX
platform.
About this class and its related classes also see IO::Spec
.
Methods§
method canonpath§
method canonpath(Str() $path, :$parent --> Str:D)
Returns a string that is a canonical representation of $path
. If :$parent
is set to true, will also clean up references to parent directories. NOTE: the routine does not access the filesystem, so no symlinks are followed.
IO::Spec::QNX.canonpath("foo//../bar/../ber").say; # OUTPUT: «foo/../bar/../ber» IO::Spec::QNX.canonpath("foo///./../bar/../ber").say; # OUTPUT: «foo/../bar/../ber» IO::Spec::QNX.canonpath("foo///./../bar/../ber", :parent).say; # OUTPUT: «ber»