Bug 20865 – Add std.path : isSubPath

Status
NEW
Severity
enhancement
Priority
P4
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2020-05-26T11:13:23Z
Last change time
2024-12-01T16:36:49Z
Keywords
pull
Assigned to
No Owner
Creator
Andre
Moved to GitHub: phobos#9795 →

Comments

Comment #0 by andre — 2020-05-26T11:13:23Z
Could you add a function isSubPath to std.path? assert("/opt".isSubPath("/opt/sub")); assert("/opt".isSubPath("/lib") == false); To be considered: - What is the result of isSubPath("/opt", "/opt") - Path and subPath needs to be resolved to absolute paths and on *ix system ~ needs to be resolved
Comment #1 by dlang-bot — 2021-07-29T19:26:29Z
@lucica28 created dlang/phobos pull request #8182 "[DSSv3] Fix issue 20865 - add function isSubPath" fixing this issue: - Fix issue 20865 - add function isSubPath https://github.com/dlang/phobos/pull/8182
Comment #2 by robert.schadek — 2024-12-01T16:36:49Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/phobos/issues/9795 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB