authorgravatar for prc.zhao@outlook.comSizhe Zhao <prc.zhao@outlook.com> 2022-12-21 15:39:21+08:00
committergravatar for git@vexu.euVeikka Tuominen <git@vexu.eu> 2023-01-03 12:49:05+02:00
log4fa027a3cceb9068db8ff432abc8ab0d464f8b33
tree44a7f98ccc1bfa0f8f60b06af3867a8d4d6dd20d
parent1de96a2cc4bf2d1be1404690d6a867eb0127d533

docs: Clarify that std.fs.path.resolve doesn't resolve relative path to

absolute path

1 files changed, 2 insertions(+), 2 deletions(-)

lib/std/fs/path.zig+2-2
...@@ -460,7 +460,7 @@ pub fn resolve(allocator: Allocator, paths: []const []const u8) ![]u8 {...@@ -460,7 +460,7 @@ pub fn resolve(allocator: Allocator, paths: []const []const u8) ![]u8 {
460}460}
461461
462/// This function is like a series of `cd` statements executed one after another.462/// This function is like a series of `cd` statements executed one after another.
463/// It resolves "." and "..".463/// It resolves "." and "..", but will not convert relative path to absolute path, use std.fs.Dir.realpath instead.
464/// The result does not have a trailing path separator.464/// The result does not have a trailing path separator.
465/// Each drive has its own current working directory.465/// Each drive has its own current working directory.
466/// Path separators are canonicalized to '\\' and drives are canonicalized to capital letters.466/// Path separators are canonicalized to '\\' and drives are canonicalized to capital letters.
...@@ -637,7 +637,7 @@ pub fn resolveWindows(allocator: Allocator, paths: []const []const u8) ![]u8 {...@@ -637,7 +637,7 @@ pub fn resolveWindows(allocator: Allocator, paths: []const []const u8) ![]u8 {
637}637}
638638
639/// This function is like a series of `cd` statements executed one after another.639/// This function is like a series of `cd` statements executed one after another.
640/// It resolves "." and "..".640/// It resolves "." and "..", but will not convert relative path to absolute path, use std.fs.Dir.realpath instead.
641/// The result does not have a trailing path separator.641/// The result does not have a trailing path separator.
642/// This function does not perform any syscalls. Executing this series of path642/// This function does not perform any syscalls. Executing this series of path
643/// lookups on the actual filesystem may produce different results due to643/// lookups on the actual filesystem may produce different results due to