method Path.normalize
Removes . components and folds .. where possible (a/./b/../c -> a/c, /../a -> /a, ../a stays).
Example:
use std.io { Path }
fn main() io {
print(Path.of("a/./b/../c").normalize().text)
}Output
a/c
pub(api) fn normalize() -> PathSince. 1.0.0-beta
Returns
Effects
none declared (pure unless the body says otherwise)
Defined in: std/io/io.oxl:1029