mirror of
https://github.com/ziglang/zig.git
synced 2026-02-19 07:48:31 +00:00
Module: use path.isSep
Co-authored-by: Veikka Tuominen <git@vexu.eu>
This commit is contained in:
parent
1110eafe9b
commit
8c4896fb3a
@ -4697,7 +4697,7 @@ pub fn importFile(
|
||||
if (!mem.startsWith(u8, resolved_path, resolved_root_path) or
|
||||
// This prevents this check from triggering when the name of the
|
||||
// imported file starts with the root path's directory name.
|
||||
mem.indexOfAny(u8, &.{resolved_path[resolved_root_path.len]}, "/\\") == null)
|
||||
std.fs.path.isSep(resolved_path[resolved_root_path.len]))
|
||||
{
|
||||
return error.ImportOutsidePkgPath;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user